Bug 12400 – Misleading/useless diagnostic on bad fully-qualified symbol name
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-03-18T04:31:00Z
Last change time
2014-03-24T00:25:17Z
Keywords
diagnostic
Assigned to
nobody
Creator
dlang-bugzilla
Comments
Comment #0 by dlang-bugzilla — 2014-03-18T04:31:50Z
//////////// test.d ////////////
import std.typecons;
alias std.typecons.Unqual!int X;
////////////////////////////////
Compiler output:
test.d(1,8): Error: import typecons template identifier 'Unqual' is not a member of 'import typecons'
test.d(1,8): Error: import typecons template identifier 'Unqual' is not a member of 'import typecons'
test.d(3,31): Error: undefined identifier 'Unqual'
The first two lines are misleading and useless.
Comment #1 by k.hara.pg — 2014-03-18T07:38:34Z
With 2.065 and earlier, the code had been compiled, but it was incorrect behavior. So the rejection itself is valid and intended result.
But I agree that the diagnostic is problematic. The reported error should be:
test.d(3): Error: undefined identifier 'Unqual' in module std.typecons