[Issue 24034] Changing this in constructor allows to modify immutable members of other instance
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jul 10 11:47:59 UTC 2023
https://issues.dlang.org/show_bug.cgi?id=24034
RazvanN <razvan.nitu1305 at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |razvan.nitu1305 at gmail.com
Severity|normal |regression
--- Comment #1 from RazvanN <razvan.nitu1305 at gmail.com> ---
Yeah, this is bad. I guess `this` should not be modifiable for classes when
used in constructors. For normal functions it could be allowed.
--
More information about the Digitalmars-d-bugs
mailing list