Testing some singleton implementations

Andrej Mitrovic andrej.mitrovich at gmail.com
Mon Feb 10 01:54:41 PST 2014


On 2/9/14, luka8088 <luka8088 at owave.net> wrote:
>   private static __gshared typeof(this) instance_;

Also, "static __gshared" is really meaningless here, it's either
static (TLS), or globally shared, either way it's not a class
instance, so you can type __gshared alone here. Otherwise I'm not sure
what the semantics of a per-class-instance __gshared field would be,
if that can exist.


More information about the Digitalmars-d mailing list