[Issue 24162] Another example of why @safe is broken

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Sep 27 02:21:08 UTC 2023


https://issues.dlang.org/show_bug.cgi?id=24162

mhh <maxhaton at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |maxhaton at gmail.com

--- Comment #5 from mhh <maxhaton at gmail.com> ---
This is a valid reason to attempt to ban mutable aliasing. It's not an uncommon
thing to try and avoid with the type system in newer languages.

Whether its valid or not is basically a matter of definition although I will
point out that in this particular example I don't know if the GC would actually
spot the reference to it because there wouldn't be much on the stack for it to
find.

--


More information about the Digitalmars-d-bugs mailing list