[Dlang-internal] DIP1000 discussion and testing
Walter Bright via Dlang-internal
dlang-internal at puremagic.com
Tue Nov 22 19:35:16 PST 2016
On 11/20/2016 8:41 AM, Mathias Lang wrote:
> And from a quick test (Using `-dip25 -transition=safe` and 5928249 which is the
> commit of this P.R.), the following code:
>
> ```
> void main () @safe
> {
> scope o = new Object();
> }
> ```
>
> Results in the following error:
> scope2.d(3): Error: delete o is not @safe but is used in @safe function main
>
> Which works with the compiler I'm currently using, 2.071.2.
This was done here back in June:
https://github.com/dlang/dmd/commit/e64ae1d3e5aa078a036242864a68499617c9b278
and was added to fix:
https://issues.dlang.org/show_bug.cgi?id=16195
The trouble is, operator delete is not safe.
What do you suggest?
More information about the Dlang-internal
mailing list