[Issue 21078] static if(is(T IDENT)) introduces IDENT beyond static if's scpe

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jul 28 02:31:59 UTC 2020


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

--- Comment #3 from Basile-z <b2.temp at gmx.com> ---
One thing is that it is specified `static if` doesn't introduce a "logical"
scope also there's one in the syntax, so "lexicographically" (let's call this
like that)

void main() {
    static if(is(int INT))
    { // <-- lexical scope but not "logical"
        INT a;
    }
    INT b;
}

--


More information about the Digitalmars-d-bugs mailing list