www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 6411] New: Undefined reference to __dgliteral in mixin


           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: nobody puremagic.com
        ReportedBy: ibuclaw ubuntu.com

--- Comment #0 from Iain Buclaw <ibuclaw ubuntu.com> 2011-07-30 09:03:33 PDT ---
The following code fails to link, but works just fine without 'mixin'.

void main()
    string foo() {
      return "";

    string bar()() {
      return foo();

    return bar();

Linker error:
bug.o: In function `_D3bug4mainFZv12__dgliteral1MFZAya8__T3barZ3barMFZAya':
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: -------
Jul 30 2011