about summary refs log tree commit diff
path: root/src/test/ui/union/union-generic.stderr
blob: f13b2def6db844d0d53f2520895776312d8e5e23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
error[E0277]: the trait bound `std::rc::Rc<u32>: std::marker::Copy` is not satisfied
  --> $DIR/union-generic.rs:8:13
   |
LL | union U<T: Copy> {
   | ---------------- required by `U`
...
LL |     let u = U { a: Rc::new(0u32) };
   |             ^ the trait `std::marker::Copy` is not implemented for `std::rc::Rc<u32>`

error[E0277]: the trait bound `std::rc::Rc<u32>: std::marker::Copy` is not satisfied
  --> $DIR/union-generic.rs:10:13
   |
LL | union U<T: Copy> {
   | ---------------- required by `U`
...
LL |     let u = U::<Rc<u32>> { a: Default::default() };
   |             ^^^^^^^^^^^^ the trait `std::marker::Copy` is not implemented for `std::rc::Rc<u32>`

error: aborting due to 2 previous errors

For more information about this error, try `rustc --explain E0277`.