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

          Issue ID: 15795
           Summary: bogus "conflicts with" error depending on order of
                    declaration
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: [email protected]
          Reporter: [email protected]

dmd rejects this:

----
template Foo(T : int) {}
template Bar(T) {}
alias Bar = Foo; /* test.d(3): Error: alias test.Bar conflicts with template
test.Bar(T) at test.d(2) */
----

But swap lines 2 and 3, and dmd accepts it:

----
template Foo(T : int) {}
alias Bar = Foo;
template Bar(T) {} /* no problem */
----

--

Reply via email to