[Issue 19441] alias this causes partial assignment
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Jan 30 01:32:37 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=19441
--- Comment #6 from Eyal <eyal at weka.io> ---
Stefan - under what circumstances does prioritizing "alias this" ever help?
Anyway, a compiler error - not changed semantics - as proposed here, should be
fine (with the ordinary caveat of __traits(compiles ...)).
Also, currently it may inconsistently choose to assign the outer or inner field
in different circumstances, which is clearly the worst of all worlds.
Assignment *always* assigning the whole lvalue is easier to explain and far
less error-prone.
--
More information about the Digitalmars-d-bugs
mailing list