digitalmars.D.bugs - [Issue 1010] New: Abstract class template does not compile when parametrized with char[]
- d-bugmail puremagic.com (35/35) Feb 28 2007 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (6/6) Mar 08 2007 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (4/4) Oct 19 2007 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (8/8) Dec 03 2008 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (22/22) Apr 23 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (6/19) Apr 23 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1010
- d-bugmail puremagic.com (13/14) Apr 23 2009 http://d.puremagic.com/issues/show_bug.cgi?id=1010
http://d.puremagic.com/issues/show_bug.cgi?id=1010 Summary: Abstract class template does not compile when parametrized with char[] Product: D Version: 1.007 Platform: PC OS/Version: Windows Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: bugzilla digitalmars.com ReportedBy: maxter i.com.ua abstract class Foo(char[] bar) { } int main(char[][] args) { return 0; } Fails to compile with the error message: hello.d:1: variable hello.bar abstract cannot be applied to variable :: === Build finished: 1 errors, 0 warnings === While this works: template Foo(char[] bar) { abstract class Foo { } } int main(char[][] args) { return 0; } --
Feb 28 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1010 ------- Comment #1 from thomas-dloop kuehne.cn 2007-03-08 10:29 ------- Added to DStress as http://dstress.kuehne.cn/run/t/template_class_20_A.d http://dstress.kuehne.cn/run/t/template_class_20_B.d --
Mar 08 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1010 ------- Comment #2 from onlystupidspamhere yahoo.se 2007-10-19 04:09 ------- This also happens with int parameters and probably with other types too. --
Oct 19 2007
http://d.puremagic.com/issues/show_bug.cgi?id=1010 gide nwawudu.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |2korden gmail.com ------- Comment #3 from gide nwawudu.com 2008-12-03 13:36 ------- *** Bug 2236 has been marked as a duplicate of this bug. *** --
Dec 03 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1010 ------- Comment #4 from gide nwawudu.com 2009-04-23 04:05 ------- Example and DStress test cases compile in D1.041. The DStress test cases fail in D2, because the template parameter is declared as a char[] rather than a string. C:\> dmd template_class_20_A.d template_class_20_A.d(17): template instance Foo!("abc") does not match template declaration Foo(char[] bar) template_class_20_A.d(17): Error: Foo!("abc") is used as a type template_class_20_A.d(17): class dstress.run.t.template_class_20_A.Bar base type must be class or interface, not void The following code compiles, should this bug be marked as a DStress issue? abstract class Foo(string bar) { } class Bar : Foo!("abc") { } int main(char[][] args) { return 0; } --
Apr 23 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1010 ------- Comment #5 from clugdbug yahoo.com.au 2009-04-23 04:15 ------- (In reply to comment #4)Example and DStress test cases compile in D1.041. The DStress test cases fail in D2, because the template parameter is declared as a char[] rather than a string. C:\> dmd template_class_20_A.d template_class_20_A.d(17): template instance Foo!("abc") does not match template declaration Foo(char[] bar) template_class_20_A.d(17): Error: Foo!("abc") is used as a type template_class_20_A.d(17): class dstress.run.t.template_class_20_A.Bar base type must be class or interface, not void The following code compiles, should this bug be marked as a DStress issue?No. DStress was only developed for D1. It's never been ported to D2. You can safely close this bug. --
Apr 23 2009
http://d.puremagic.com/issues/show_bug.cgi?id=1010 smjg iname.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |smjg iname.com Status|NEW |RESOLVED Resolution| |WORKSFORME ------- Comment #6 from smjg iname.com 2009-04-23 14:10 ------- (In reply to comment #5)No. DStress was only developed for D1. It's never been ported to D2.Moreover, if it had, it would certainly not have been completely changed into a D2 test suite, but have some built-in distinction between D1 and D2 testcases. But still, the testcases here and in DStress WFM (1.042 Win). --
Apr 23 2009