[Issue 19517] Spurious compiler warning with const toHash and alias this classes

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Jan 16 00:03:32 UTC 2019


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

Simon Naarmann <eiderdaus at gmail.com> changed:

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

--- Comment #1 from Simon Naarmann <eiderdaus at gmail.com> ---
Right, this has nothing to do with Nullable in particular. This warning
appeared in my existing codebase after I switched from DMD 2.083.2 to 2.084.0,
and the codebase doesn't use Nullable.

The workaround is to remove the 'alias this' in S.

But it's very common to wrap class references in structs and then alias-this to
the class. Would love to see a quick fix!

--


More information about the Digitalmars-d-bugs mailing list