Debian Codegraph @

.cargo/vendor/zerocopy/tests/ui-nightly/transmute-mut-src-not-frombytes.stderr

raw
1 error[E0277]: the trait bound `Src: FromBytes` is not satisfied
2 --> tests/ui-nightly/transmute-mut-src-not-frombytes.rs:24:38
3 |
4 24 | const SRC_NOT_FROM_BYTES: &mut Dst = transmute_mut!(&mut Src);
5 | ^^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
6 |
7 help: the trait `FromBytes` is not implemented for `Src`
8 --> tests/ui-nightly/transmute-mut-src-not-frombytes.rs:17:1
9 |
10 17 | struct Src;
11 | ^^^^^^^^^^
12 = note: Consider adding `#[derive(FromBytes)]` to `Src`
13 = help: the following other types implement trait `FromBytes`:
14 ()
15 AtomicI16
16 AtomicI32
17 AtomicI64
18 AtomicI8
19 AtomicIsize
20 AtomicU16
21 AtomicU32
22 and $N others
23 note: required by a bound in `Wrap::<&'a mut Src, &'a mut Dst>::transmute_mut`
24 --> src/util/macro_util.rs
25 |
26 | pub fn transmute_mut(self) -> &'a mut Dst
27 | ------------- required by a bound in this associated function
28 | where
29 | Src: FromBytes + IntoBytes,
30 | ^^^^^^^^^ required by this bound in `Wrap::<&mut Src, &mut Dst>::transmute_mut`
31 = note: this error originates in the macro `transmute_mut` (in Nightly builds, run with -Z macro-backtrace for more info)