//DIAGNOSTIC_TEST:SIMPLE(filecheck=CHECK): -target spirv -entry computeMain -stage compute enum A { V1, V2, V3 } enum B { V1, V2, V3 } struct Foo { int a; __init(int b) { a = b; } __init(Foo ptr) { } // internally Slang is throwing an error, we just don't drain the error // from our sink __init(uint64_t val) {} __init(int64_t val) {} } extension int64_t { __init(Foo t) {} } extension uint64_t { __init(Foo t) {} } RWStructuredBuffer output; [shader("compute")] [numthreads(1, 1, 1)] void computeMain(uint3 threadId: SV_DispatchThreadID) { Foo v1 = Foo(1); // CHECK: ([[# @LINE+1]]): error 30080 Foo v2 = Foo(v1); output[0] = v1.a; }