[Issue 20868] DIP1000: scope delegate is implicitly convertible to non-scope delegate
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jan 11 11:48:26 UTC 2021
https://issues.dlang.org/show_bug.cgi?id=20868
RazvanN <razvan.nitu1305 at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |razvan.nitu1305 at gmail.com
--- Comment #1 from RazvanN <razvan.nitu1305 at gmail.com> ---
The scope analysis is done only for @safe functions. Annotating scoped and
non-scoped with @safe is going to trigger the error: 'scope variable `dg`
assigned to non-scope parameter `dg` calling test.nonScoped'.
So the actual error is that `dgs ~= dg` triggers an error in unsafe code.
--
More information about the Digitalmars-d-bugs
mailing list