Bug 11144 – Better diagnostic for typeid symbol

Status
RESOLVED
Resolution
FIXED
Severity
minor
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2013-09-29T23:12:00Z
Last change time
2013-09-30T01:28:16Z
Keywords
diagnostic, pull
Assigned to
nobody
Creator
k.hara.pg

Comments

Comment #0 by k.hara.pg — 2013-09-29T23:12:19Z
From fail_compilation/fail235.d: template Tuple(TPL...) { alias TPL Tuple; } auto K = Tuple!(typeid(char)); // Line 5 template Alias(alias A) { alias A Alias; } auto A = Alias!(typeid(char)); // Line 11 Prints: test.d(5): Error: expression & D10TypeInfo_a6__initZ is not a valid template value argument test.d(11): Error: expression & D10TypeInfo_a6__initZ is not a valid template value argument I think printing mangled symbol name is not good. Instead it should print: test.d(5): Error: expression typeid(char) is not a valid template value argument test.d(11): Error: expression typeid(char) is not a valid template value argument
Comment #1 by k.hara.pg — 2013-09-29T23:15:50Z
Comment #2 by github-bugzilla — 2013-09-30T01:28:03Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/ba80caade73ef92d2b53e66af853d3bda215d308 fix Issue 11144 - Better diagnostic for typeid symbol https://github.com/D-Programming-Language/dmd/commit/4e0e6b7eea0f82d5e00a5be65c8eb1206de04a0b Merge pull request #2600 from 9rnsr/fix11144 Issue 11144 - Better diagnostic for typeid symbol