module 0x42::M { struct S1 { // A phantom parameter cannot be used as the type of a field a: T, // The parameter of vector is non-phantom and a phantom parameter shouldn't be allowed in that position b: vector } // A phantom parameter cannot be used as the argument to a non-phantom parameter struct S2 { a: T } struct S3 { a: S2 } // Phantom position violation inside another type argument struct S4 { a: S2> } // Mixing phantom and non-phantom parameters struct S5 { a: T1, b: T2, c: T3 } // Phantom parameters should satisfy constraints struct S6 { a: bool } struct S7 { a: S6 } }