www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 15565] New: Forward reference error with namespaces

https://issues.dlang.org/show_bug.cgi?id=15565

          Issue ID: 15565
           Summary: Forward reference error with namespaces
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: bugzilla digitalmars.com

The following fails:

  alias X2 = X;
  extern (C++, ns) struct X {}

  Error: undefined identifier 'X

But the following succeeds:

  extern (C++, ns) struct X {}
  alias X2 = X;

Both should succeed.

--
Jan 13