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

--- Comment #1 from [email protected] ---
I've tried to simplify the issue with `inout`:
```
struct U8  {  }

enum canCreateVariable(T) = __traits(compiles, { T val; });

struct ContainsU8 {
    U8 text;
    auto withInout() inout {
        foo(text);
    }
    auto normal() {
        foo(text);
    }
}

void foo(T)(T obj)
{
    pragma(msg, T);
    pragma(msg, canCreateVariable!T);
}

void main() {
    ContainsU8 a;
}
```
Outputs:
inout(U8)
false
U8
true

--

Reply via email to