Bug 20696 – Should error when retrieving mangling while the type is not yet final

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2020-03-24T08:51:50Z
Last change time
2020-03-28T14:22:58Z
Keywords
pull
Assigned to
No Owner
Creator
Walter Bright
See also
https://issues.dlang.org/show_bug.cgi?id=17541, https://issues.dlang.org/show_bug.cgi?id=15431

Comments

Comment #0 by bugzilla — 2020-03-24T08:51:50Z
Consider: ----- struct S() { int test() { pragma(msg, test.mangleof); return 3; } } S!() s; ----- This should give an error, because attributes that affect mangling are not known until the semantic analysis is complete.
Comment #1 by dlang-bot — 2020-03-24T08:56:42Z
@WalterBright created dlang/dmd pull request #10961 "Fix Issue 20696 - Should error when retrieving mangling while the typ…" fixing this issue: - Fix Issue 20696 - Should error when retrieving mangling while the type is not yet final https://github.com/dlang/dmd/pull/10961
Comment #2 by pro.mathias.lang — 2020-03-24T10:19:31Z
Comment #3 by bugzilla — 2020-03-24T19:03:07Z
15431 is related, but a different problem requiring a different solution.
Comment #4 by dlang-bot — 2020-03-28T14:22:58Z
dlang/dmd pull request #10961 "Fix Issue 20696 - Should error when retrieving mangling while the typ…" was merged into master: - c4e6520f862b80dbb3756c05c29a4fcd25aa7d5d by Walter Bright: Fix Issue 20696 - Should error when retrieving mangling while the type is not yet final https://github.com/dlang/dmd/pull/10961