Debian Codegraph @

.cargo/vendor/zerocopy/tests/ui-nightly/try_transmute_ref-dst-not-immutable-tryfrombytes.stderr

raw
1 error[E0277]: the trait bound `NotZerocopy: zerocopy::TryFromBytes` is not satisfied
2 --> tests/ui-nightly/try_transmute_ref-dst-not-immutable-tryfrombytes.rs:19:33
3 |
4 19 | let dst_not_try_from_bytes: Result<&NotZerocopy, _> = try_transmute_ref!(&AU16(0));
5 | ^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
6 |
7 help: the trait `zerocopy::TryFromBytes` is not implemented for `NotZerocopy`
8 --> tests/ui-nightly/../../zerocopy-derive/tests/include.rs
9 |
10 48 | pub struct NotZerocopy<T = ()>(pub T);
11 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
12 = note: Consider adding `#[derive(TryFromBytes)]` to `NotZerocopy`
13 = help: the following other types implement trait `zerocopy::TryFromBytes`:
14 ()
15 *const T
16 *mut T
17 AU16
18 AtomicBool
19 AtomicI16
20 AtomicI32
21 AtomicI64
22 and $N others
23 note: required by a bound in `ValidityError`
24 --> src/error.rs
25 |
26 | pub struct ValidityError<Src, Dst: ?Sized + TryFromBytes> {
27 | ^^^^^^^^^^^^ required by this bound in `ValidityError`
28
29 error[E0277]: the trait bound `NotZerocopy: zerocopy::TryFromBytes` is not satisfied
30 --> tests/ui-nightly/try_transmute_ref-dst-not-immutable-tryfrombytes.rs:19:59
31 |
32 19 | let dst_not_try_from_bytes: Result<&NotZerocopy, _> = try_transmute_ref!(&AU16(0));
33 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
34 |
35 help: the trait `zerocopy::TryFromBytes` is not implemented for `NotZerocopy`
36 --> tests/ui-nightly/../../zerocopy-derive/tests/include.rs
37 |
38 48 | pub struct NotZerocopy<T = ()>(pub T);
39 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
40 = note: Consider adding `#[derive(TryFromBytes)]` to `NotZerocopy`
41 = help: the following other types implement trait `zerocopy::TryFromBytes`:
42 ()
43 *const T
44 *mut T
45 AU16
46 AtomicBool
47 AtomicI16
48 AtomicI32
49 AtomicI64
50 and $N others
51 note: required by a bound in `try_transmute_ref`
52 --> src/util/macro_util.rs
53 |
54 | pub fn try_transmute_ref<Src, Dst>(src: &Src) -> Result<&Dst, ValidityError<&Src, Dst>>
55 | ----------------- required by a bound in this function
56 ...
57 | Dst: TryFromBytes + Immutable,
58 | ^^^^^^^^^^^^ required by this bound in `try_transmute_ref`
59 = note: this error originates in the macro `try_transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
60
61 error[E0277]: the trait bound `NotZerocopy: zerocopy::Immutable` is not satisfied
62 --> tests/ui-nightly/try_transmute_ref-dst-not-immutable-tryfrombytes.rs:19:59
63 |
64 19 | let dst_not_try_from_bytes: Result<&NotZerocopy, _> = try_transmute_ref!(&AU16(0));
65 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
66 |
67 help: the trait `zerocopy::Immutable` is not implemented for `NotZerocopy`
68 --> tests/ui-nightly/../../zerocopy-derive/tests/include.rs
69 |
70 48 | pub struct NotZerocopy<T = ()>(pub T);
71 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
72 = note: Consider adding `#[derive(Immutable)]` to `NotZerocopy`
73 = help: the following other types implement trait `zerocopy::Immutable`:
74 &T
75 &mut T
76 ()
77 *const T
78 *mut T
79 AU16
80 Box<T>
81 F32<O>
82 and $N others
83 note: required by a bound in `try_transmute_ref`
84 --> src/util/macro_util.rs
85 |
86 | pub fn try_transmute_ref<Src, Dst>(src: &Src) -> Result<&Dst, ValidityError<&Src, Dst>>
87 | ----------------- required by a bound in this function
88 ...
89 | Dst: TryFromBytes + Immutable,
90 | ^^^^^^^^^ required by this bound in `try_transmute_ref`
91 = note: this error originates in the macro `try_transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
92
93 error[E0277]: the trait bound `NotZerocopy: zerocopy::TryFromBytes` is not satisfied
94 --> tests/ui-nightly/try_transmute_ref-dst-not-immutable-tryfrombytes.rs:19:59
95 |
96 19 | let dst_not_try_from_bytes: Result<&NotZerocopy, _> = try_transmute_ref!(&AU16(0));
97 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound
98 |
99 help: the trait `zerocopy::TryFromBytes` is not implemented for `NotZerocopy`
100 --> tests/ui-nightly/../../zerocopy-derive/tests/include.rs
101 |
102 48 | pub struct NotZerocopy<T = ()>(pub T);
103 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
104 = note: Consider adding `#[derive(TryFromBytes)]` to `NotZerocopy`
105 = help: the following other types implement trait `zerocopy::TryFromBytes`:
106 ()
107 *const T
108 *mut T
109 AU16
110 AtomicBool
111 AtomicI16
112 AtomicI32
113 AtomicI64
114 and $N others
115 note: required by a bound in `ValidityError`
116 --> src/error.rs
117 |
118 | pub struct ValidityError<Src, Dst: ?Sized + TryFromBytes> {
119 | ^^^^^^^^^^^^ required by this bound in `ValidityError`
120 = note: this error originates in the macro `try_transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)