[Issue 22193] New: is expression not understanding global scope operator

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Aug 9 15:48:47 UTC 2021


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

          Issue ID: 22193
           Summary: is expression not understanding global scope operator
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: druntime
          Assignee: nobody at puremagic.com
          Reporter: destructionator at gmail.com

This works fine:

```
struct Foo(F) if (is(F == FooT!T, T)) {}
struct FooT(T) {}

void main()
{
    Foo!(FooT!int) foo;
}
```

But this does not:

```
struct Foo(FooT) if (is(FooT == .FooT!T, T)) {}
struct FooT(T) {}

void main()
{
    Foo!(FooT!int) foo;
}
```

app.d(1): Error: undefined identifier `T`
app.d(6):        while looking for match for `Foo!(FooT!int)`


It seems to just ignore the leading dot.

--


More information about the Digitalmars-d-bugs mailing list