Bug 15431 – pragma mangle and mangleof are order dependent

Status
NEW
Severity
normal
Priority
P3
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-12-10T04:47:12Z
Last change time
2024-12-13T18:46:04Z
Assigned to
No Owner
Creator
Richard (Rikki) Andrew Cattermole
See also
https://issues.dlang.org/show_bug.cgi?id=20696, https://issues.dlang.org/show_bug.cgi?id=22620
Moved to GitHub: dmd#17738 →

Comments

Comment #0 by alphaglosined — 2015-12-10T04:47:12Z
Given some test code as: pragma(msg, mySymbol.mangleof); pragma(mangle, "_mySymbolIsThis") void mySymbol() { import std.stdio : writeln; writeln("mySymbol"); } pragma(msg, mySymbol.mangleof); The output is: _D4f2008mySymbolFZv _mySymbolIsThis The order of mangleof should not matter to the output. It's silly because extern(C) is taking more into account then pragma(mangle is here.
Comment #1 by bugzilla — 2020-03-24T19:56:26Z
A probable solution is to move the pragma (and static assert) processing to semantic2 rather than the first pass.
Comment #2 by robert.schadek — 2024-12-13T18:46:04Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/17738 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB