http://d.puremagic.com/issues/show_bug.cgi?id=6879
Summary: The difference of between template matching and IsExp Product: D Version: D2 Platform: Other OS/Version: Windows Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nob...@puremagic.com ReportedBy: k.hara...@gmail.com --- Comment #0 from Kenji Hara <k.hara...@gmail.com> 2011-11-02 04:57:00 PDT --- I think following code should compile. ---- private template isStaticArray(T : U[N], U, size_t N) { enum bool isStaticArray = true; } private template isStaticArray(T) { enum bool isStaticArray = false; } void main() { alias int[3] T; enum res1 = isStaticArray!T; static if (is(T _ : U[N], U, size_t N)) enum res2 = true; else enum res2 = false; static assert(res1 == res2); // fails... Why? } -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------