Bug 15795 – bogus "conflicts with" error depending on order of declaration
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2016-03-14T10:13:34Z
Last change time
2019-07-04T08:47:59Z
Keywords
pull, rejects-valid
Assigned to
No Owner
Creator
ag0aep6g
Comments
Comment #0 by ag0aep6g — 2016-03-14T10:13:34Z
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 */
----
Comment #1 by dlang-bot — 2019-06-23T21:10:51Z
@Basile-z created dlang/dmd pull request #10078 "fix issue 15795 - bogus "conflicts with" error depending on order of declaration" fixing this issue:
- fix issue 15795 - bogus "conflicts with" error depending on order of declaration
https://github.com/dlang/dmd/pull/10078
Comment #2 by dlang-bot — 2019-07-04T08:47:59Z
dlang/dmd pull request #10078 "fix issue 15795 - bogus "conflicts with" error depending on order of declaration" was merged into master:
- 9824fb2e8e92c6744e48054f2a2204cf99ca2d08 by Basile Burg:
fix issue 15795 - bogus "conflicts with" error depending on order of declaration
https://github.com/dlang/dmd/pull/10078