https://issues.dlang.org/show_bug.cgi?id=22139
Issue ID: 22139
Summary: Compiler special cases object.dup when compiling with
-preview=dip1000
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P1
Component: dmd
Assignee: [email protected]
Reporter: [email protected]
...as a workaround because it apparently breaks purity inference. This is
problematic because it indicates that custom implementations will most likely
be broken because they don't receive special treatment.
See
https://github.com/dlang/dmd/blob/3a9c2891b1f5bd650c42c2e623fbc3340d4d84f6/src/dmd/dcast.d#L855-L870
--