Summary: Segmantation fault, if exclamation mark absent
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from Tobias Pankrath <> 2011-11-17 12:58:35 
PST ---
Note the missing exclamation marks in Pred(A, B[0]) || ...
The compiler dies with "Segmantation fault".

import std.typetuple;
import std.stdio;

template Pred(A, B)
    static if(is(B == int))
        enum bool Pred = true;
        enum bool Pred = false;

template PredAny(A, B...)
    static if(B.length == 0)
        enum bool PredAny = false;
        enum bool PredAny = Pred(A, B[0]) || PredAny(A, B[1..$]);

void main()
    pragma(msg, PredAny!(int, long, ulong, int, size_t, double, float));

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to