www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 8024] New: Template alias parameter is fail to compile when -inline is used

http://d.puremagic.com/issues/show_bug.cgi?id=8024

           Summary: Template alias parameter is fail to compile when
                    -inline is used
           Product: D
           Version: D1
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: leandro.lucarella sociomantic.com



2012-05-03 05:07:59 PDT ---
---
void foo(alias f)() {
    f();
}

void bar() {
        foo!({})();
}

void main() {
        bar();
}
---

dmd -inline -c m1.d
m1.d(1): Error: function m1.bar.foo!(delegate void()
{
}
).foo is a nested function and cannot be accessed from main

Pretty similar to bug 5499 but not the same as the failures are so different.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
May 03 2012