digitalmars.D.bugs - [Issue 5116] New: Too many error messages with failed template constraint
- d-bugmail puremagic.com (33/33) Oct 24 2010 http://d.puremagic.com/issues/show_bug.cgi?id=5116
- d-bugmail puremagic.com (19/19) Feb 24 2012 http://d.puremagic.com/issues/show_bug.cgi?id=5116
http://d.puremagic.com/issues/show_bug.cgi?id=5116 Summary: Too many error messages with failed template constraint Product: D Version: D2 Platform: x86 OS/Version: Windows Status: NEW Keywords: diagnostic Severity: minor Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: bearophile_hugs eml.cc This is a wrong D2 program: struct Foo {} class Bar(T) if (!is(T == struct)) {} void main() { auto b = new Bar!Foo(); } DMD 2.049 shows the following compile errors: test.d(4): Error: template instance Bar!(Foo) does not match template declaration Bar(T) if (!is(T == struct)) test.d(4): Error: Bar!(Foo) is used as a type test.d(4): Error: new can only create structs, dynamic arrays or class objects, not void's But minimizing error messages noise is good to speed up debugging and to make coding simpler. So in this case I'd like to receive only the first error message. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Oct 24 2010
http://d.puremagic.com/issues/show_bug.cgi?id=5116 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |clugdbug yahoo.com.au Version|D2 |D1 & D2 Summary|Too many error messages |spurious 'is used as a |with failed template |type' error after template |constraint |lookup error Nothing to with templates. Same thing happens with: struct Foo {} class Bar(int n) void main() { auto b = new Bar!Foo(); } -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 24 2012