Bug 7465 – Duplicate error message for bad template mixin

Status
RESOLVED
Resolution
FIXED
Severity
minor
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2012-02-08T13:31:00Z
Last change time
2014-08-26T07:42:12Z
Keywords
diagnostic
Assigned to
nobody
Creator
clugdbug

Comments

Comment #0 by clugdbug — 2012-02-08T13:31:54Z
From the test suite, fail10.d template Foo(alias b){} mixin Foo!(y) y; crash.d(2): Error: mixin crash.Foo!(y) cannot resolve forward reference crash.d(2): Error: mixin crash.Foo!(y) cannot resolve forward reference
Comment #1 by andrej.mitrovich — 2013-02-24T13:23:54Z
Getting worse, it's now 3 error messages in 2.062. :)
Comment #2 by k.hara.pg — 2014-08-26T07:42:12Z
The duplication is disappeared with 2.066. And the file fail_compilation/fail10.d is now properly testing the diagnostic. /* TEST_OUTPUT: --- fail_compilation/fail10.d(18): Error: mixin Foo!y cannot resolve forward reference --- */ template Foo(alias b) { int a() { return b; } } void test() { mixin Foo!(y) y; }