diff options
Diffstat (limited to 'gcc/testsuite/rust/compile/method2.rs')
-rw-r--r-- | gcc/testsuite/rust/compile/method2.rs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/rust/compile/method2.rs b/gcc/testsuite/rust/compile/method2.rs new file mode 100644 index 0000000..c8699f7 --- /dev/null +++ b/gcc/testsuite/rust/compile/method2.rs @@ -0,0 +1,16 @@ +struct Foo<A, B>(A, B); + +impl Foo<i32, f32> { + fn test<X>(self, a: X) -> X { + a + } +} + +fn main() { + let a; + a = Foo(123, 456f32); + + let b; + b = a.test::<asfasfr>(false); + // { dg-error "failed to resolve TypePath: asfasfr" "" { target *-*-* } .-1 } +} |