August 08, 2013 [Issue 10778] New: Can't define a std.typecons.Typedef of a significant 2D matrix | ||||
---|---|---|---|---|
| ||||
http://d.puremagic.com/issues/show_bug.cgi?id=10778 Summary: Can't define a std.typecons.Typedef of a significant 2D matrix Product: D Version: D2 Platform: x86 OS/Version: Windows Status: NEW Keywords: rejects-valid Severity: normal Priority: P2 Component: DMD AssignedTo: nobody@puremagic.com ReportedBy: bearophile_hugs@eml.cc --- Comment #0 from bearophile_hugs@eml.cc 2013-08-08 07:42:07 PDT --- import std.typecons: Typedef; alias Matrix = double[260][260]; alias Foo = Typedef!Matrix; void main() {} dmd 2.064alpha gives: test.d(3): Error: template instance std.typecons.Typedef!(double[360u][260u]) recursive expansion My main use case for Typedef is with arrays, to tell them apart, to avoid bugs. This used to work correctly: alias Matrix = double[260][260]; typedef Matrix Foo; void main() { Foo m; } -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation