]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-50480.rs
better ObligationCause for normalization errors in can_type_implement_copy
[rust.git] / src / test / ui / issues / issue-50480.rs
1 #[derive(Clone, Copy)]
2 //~^ ERROR the trait `Copy` may not be implemented for this type
3 //~| ERROR `i32` is not an iterator
4 struct Foo(N, NotDefined, <i32 as Iterator>::Item, Vec<i32>, String);
5 //~^ ERROR cannot find type `NotDefined` in this scope
6 //~| ERROR cannot find type `NotDefined` in this scope
7 //~| ERROR cannot find type `N` in this scope
8 //~| ERROR cannot find type `N` in this scope
9
10 #[derive(Clone, Copy)]
11 //~^ ERROR the trait `Copy` may not be implemented for this type
12 //~| ERROR `i32` is not an iterator
13 struct Bar<T>(T, N, NotDefined, <i32 as Iterator>::Item, Vec<i32>, String);
14 //~^ ERROR cannot find type `NotDefined` in this scope
15 //~| ERROR cannot find type `N` in this scope
16
17 fn main() {}