[Issue 19882] New: Expected 'undefined identifier' error when type comparing

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat May 18 03:10:09 UTC 2019


https://issues.dlang.org/show_bug.cgi?id=19882

          Issue ID: 19882
           Summary: Expected 'undefined identifier' error when type
                    comparing
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: minor
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: patric.dexheimer at gmail.com

void main()
{
    static if( is(undefined_id == int) ) pragma(msg, "OK");
        //compiles
        //oops

    //static if( is(int == undefined_id ) ) pragma(msg, "OK"); 
        //Error: undefined identifier undefined_type 
        //as expected
}

--


More information about the Digitalmars-d-bugs mailing list