[Issue 13113] cannot build druntime's gc.d with -debug=INVARIANT, bad @nogc inference?
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Tue Jul 15 21:35:23 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=13113
Kenji Hara <k.hara.pg at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|major |regression
--- Comment #9 from Kenji Hara <k.hara.pg at gmail.com> ---
(In reply to Rainer Schuetze from comment #8)
> > So, the original issue is not a compiler regression. It was introduced by druntime change in Gcx class invariant code.
>
> I cannot test the current gc.d code with dmd 2.065 because of other changes,
> but the reduced test case works with that version. Isn't this a regression
> for user code, too?
OK... make sense.
So, I'd propose that direct invariant calls in constructor and destructor
should bypass attribute enforcement.
https://github.com/D-Programming-Language/dmd/pull/3775
Of course it is debatable behavior, but attribute enforcement does not work _at
all_ on virtual invariant calls in normal member functions, so the change
itself would not make things much worse.
--
More information about the Digitalmars-d-bugs
mailing list