digitalmars.D.bugs - [Issue 10705] New: recursive alias declaration
- d-bugmail puremagic.com (40/40) Jul 23 2013 http://d.puremagic.com/issues/show_bug.cgi?id=10705
http://d.puremagic.com/issues/show_bug.cgi?id=10705 Summary: recursive alias declaration Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: rswhite4 googlemail.com ---- import std.stdio; struct Rect(T) { public: bool intersects(ref const Rect!T rhs, ShortRect* overlap = null) { return false; } } alias FloatRect = Rect!float; alias ShortRect = Rect!short; void main() { } ---- print: tpl_bug.d(11): Error: alias tpl_bug.ShortRect recursive alias declaration tpl_bug.d(11): Error: template instance tpl_bug.Rect!(short) error instantiating tpl_bug.d(10): Error: template instance tpl_bug.Rect!(float) error instantiating dmd 2.063.2, Windows Seems the Compiler is a bit confused. If I change 'ShortRect' to 'Rect!short' or 'Rect!T' everything works fine. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Jul 23 2013