is my code to get CTFE instantiated object valid D ?
Kagamin via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Fri May 27 14:41:02 PDT 2016
On Friday, 27 May 2016 at 20:20:36 UTC, chmike wrote:
> Is this code valid D or is the behavior undefined due to the
> cast ?
A mutable object can be synchronized on:
synchronized(Category.instance){}
This will create and store a mutex in the object (sad but true,
design taken from java). If the immutable object is in readonly
memory, it will crash on write.
More information about the Digitalmars-d-learn
mailing list