Skip to content

Commit 35b2960

Browse files
committed
Add another test for #3177
1 parent 1f81e4c commit 35b2960

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
// xfail-test
2+
// error-pattern: instantiating a type parameter with an incompatible type
3+
struct S<T: Const> {
4+
s: T,
5+
mut cant_nest: ()
6+
}
7+
8+
fn main() {
9+
let a1 = ~S{ s: true, cant_nest: () };
10+
let _a2 = ~S{ s: move a1, cant_nest: () };
11+
}

0 commit comments

Comments
 (0)