http://d.puremagic.com/issues/show_bug.cgi?id=6411
Summary: Undefined reference to __dgliteral in mixin
Product: D
Version: D1 & D2
Platform: Other
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from Iain Buclaw <[email protected]> 2011-07-30 09:03:33 PDT ---
The following code fails to link, but works just fine without 'mixin'.
void main()
{
mixin({
string foo() {
return "";
}
string bar()() {
return foo();
}
return bar();
}());
}
Linker error:
bug.o: In function `_D3bug4mainFZv12__dgliteral1MFZAya8__T3barZ3barMFZAya':
bug.d:(.text._D3bug4mainFZv12__dgliteral1MFZAya8__T3barZ3barMFZAya+0x7):
undefined reference to `_D3bug4mainFZv12__dgliteral1MFZAya3fooMFZAya'
collect2: ld returned 1 exit status
--- errorlevel 1
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------