Discussion Thread: DIP 1035-- at system Variables--Community Review Round 1

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Wed Jun 17 12:41:57 UTC 2020


On 6/17/20 2:14 AM, Timon Gehr wrote:
> 
>> Embellishments are immediate (ctors, allowing void init, opAssign, 
>> etc). To the extent this type can be pried open in @safe code, these 
>> are definitely bugs in the existing language.
> 
> Not all of them, though the fact that it has a default constructor 
> `this(T value){ this.value = value; }` is a bug.

Ehm. The structure given was a minimal sketch, not an attempt at a 
complete implementation. An implementation could choose to disable the 
constructor or define it as @system etc.

> Maybe you can make it 
> work the way you envision, but what is to stop someone from coming along 
> and adding some more @safe code to that module?

A code review.


More information about the Digitalmars-d mailing list