1error[E0277]: the trait bound `NotZerocopy: zerocopy::Immutable` is not satisfied 2 --> tests/ui-nightly/diagnostic-not-implemented-issue-1296.rs:52:19 3 | 452 | Foo.write_obj(NotZerocopy(())); 5 | --------- ^^^^^^^^^^^^^^^ the trait `zerocopy::Immutable` is not implemented for `NotZerocopy` 6 | | 7 | required by a bound introduced by this call 8 | 9note: required by a bound in `Foo::write_obj` 10 --> tests/ui-nightly/diagnostic-not-implemented-issue-1296.rs:58:21 11 | 1258 | fn write_obj<T: Immutable + IntoBytes>(&mut self, _val: T) {} 13 | ^^^^^^^^^ required by this bound in `Foo::write_obj` 14help: consider borrowing here 15 | 1652 | Foo.write_obj(&NotZerocopy(())); 17 | + 1852 | Foo.write_obj(&mut NotZerocopy(())); 19 | ++++ 20 21error[E0277]: the trait bound `NotZerocopy: zerocopy::IntoBytes` is not satisfied 22 --> tests/ui-nightly/diagnostic-not-implemented-issue-1296.rs:52:19 23 | 2452 | Foo.write_obj(NotZerocopy(())); 25 | --------- ^^^^^^^^^^^^^^^ the trait `zerocopy::IntoBytes` is not implemented for `NotZerocopy` 26 | | 27 | required by a bound introduced by this call 28 | 29 = note: Consider adding `#[derive(IntoBytes)]` to `NotZerocopy` 30 = help: the following other types implement trait `zerocopy::IntoBytes`: 31 () 32 AU16 33 AtomicBool 34 AtomicI16 35 AtomicI32 36 AtomicI64 37 AtomicI8 38 AtomicIsize 39 and $N others 40note: required by a bound in `Foo::write_obj` 41 --> tests/ui-nightly/diagnostic-not-implemented-issue-1296.rs:58:33 42 | 4358 | fn write_obj<T: Immutable + IntoBytes>(&mut self, _val: T) {} 44 | ^^^^^^^^^ required by this bound in `Foo::write_obj` 45