digitalmars.D.bugs - Compiler hangs on recursive template
- Nick (10/10) Jun 10 2005 DMD hangs when trying to compile the following:
- Walter (2/2) Jun 10 2005 Weeelll, it eventually will fail with a stack fault. It just takes a lon...
- Thomas Kuehne (12/21) Jun 10 2005 -----BEGIN PGP SIGNED MESSAGE-----
DMD hangs when trying to compile the following: template AA(int i) { class A : AA!(i+1).A {} } alias AA!(0).A A0; If you add something that stops the recursion somehow, for example template AA(int i : 20) {class A {}} then it works as expected. I'm using 0.126 on linux. Nick
Jun 10 2005
Weeelll, it eventually will fail with a stack fault. It just takes a long time.
Jun 10 2005
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Nick schrieb am Fri, 10 Jun 2005 11:30:02 +0000 (UTC):DMD hangs when trying to compile the following: template AA(int i) { class A : AA!(i+1).A {} } alias AA!(0).A A0; If you add something that stops the recursion somehow, for example template AA(int i : 20) {class A {}} then it works as expected. I'm using 0.126 on linux.Added to DStress as http://dstress.kuehne.cn/nocompile/t/template_16.d http://dstress.kuehne.cn/nocompile/t/template_class_09.d Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFCqoNn3w+/yD4P9tIRAhr+AJ9rLyXxhMjgESLACEeEtY/C6jwoJwCfclV+ xZ65YRJ03oKc2IhClPz4wOA= =95Q3 -----END PGP SIGNATURE-----
Jun 10 2005