diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:06:31 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 12:06:31 +0000 |
commit | 2ff14448863ac1a1dd9533461708e29aae170c2d (patch) | |
tree | 85b9fea2bbfe3f06473cfa381eed11f273b57c5c /src/test/ui/object-lifetime/object-lifetime-default.rs | |
parent | Adding debian version 1.64.0+dfsg1-1. (diff) | |
download | rustc-2ff14448863ac1a1dd9533461708e29aae170c2d.tar.xz rustc-2ff14448863ac1a1dd9533461708e29aae170c2d.zip |
Adding debian version 1.65.0+dfsg1-2.debian/1.65.0+dfsg1-2
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/test/ui/object-lifetime/object-lifetime-default.rs')
-rw-r--r-- | src/test/ui/object-lifetime/object-lifetime-default.rs | 44 |
1 files changed, 35 insertions, 9 deletions
diff --git a/src/test/ui/object-lifetime/object-lifetime-default.rs b/src/test/ui/object-lifetime/object-lifetime-default.rs index 60b6629e6..74f5bb7dd 100644 --- a/src/test/ui/object-lifetime/object-lifetime-default.rs +++ b/src/test/ui/object-lifetime/object-lifetime-default.rs @@ -1,24 +1,50 @@ #![feature(rustc_attrs)] #[rustc_object_lifetime_default] -struct A<T>(T); //~ ERROR BaseDefault +struct A< + T, //~ ERROR BaseDefault +>(T); #[rustc_object_lifetime_default] -struct B<'a,T>(&'a (), T); //~ ERROR BaseDefault +struct B< + 'a, + T, //~ ERROR BaseDefault +>(&'a (), T); #[rustc_object_lifetime_default] -struct C<'a,T:'a>(&'a T); //~ ERROR 'a +struct C< + 'a, + T: 'a, //~ ERROR 'a +>(&'a T); #[rustc_object_lifetime_default] -struct D<'a,'b,T:'a+'b>(&'a T, &'b T); //~ ERROR Ambiguous +struct D< + 'a, + 'b, + T: 'a + 'b, //~ ERROR Ambiguous +>(&'a T, &'b T); #[rustc_object_lifetime_default] -struct E<'a,'b:'a,T:'b>(&'a T, &'b T); //~ ERROR 'b +struct E< + 'a, + 'b: 'a, + T: 'b, //~ ERROR 'b +>(&'a T, &'b T); #[rustc_object_lifetime_default] -struct F<'a,'b,T:'a,U:'b>(&'a T, &'b U); //~ ERROR 'a,'b +struct F< + 'a, + 'b, + T: 'a, //~ ERROR 'a + U: 'b, //~ ERROR 'b +>(&'a T, &'b U); #[rustc_object_lifetime_default] -struct G<'a,'b,T:'a,U:'a+'b>(&'a T, &'b U); //~ ERROR 'a,Ambiguous - -fn main() { } +struct G< + 'a, + 'b, + T: 'a, //~ ERROR 'a + U: 'a + 'b, //~ ERROR Ambiguous +>(&'a T, &'b U); + +fn main() {} |