Debian Codegraph @

third_party/rust/zerocopy/tests/ui-stable/transmute-ref-src-unsized.stderr

raw
1 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
2 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
3 |
4 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
5 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
6 | |
7 | doesn't have a size known at compile-time
8 | required by a bound introduced by this call
9 |
10 = help: the trait `Sized` is not implemented for `[u8]`
11 note: required by a bound in `AssertIsAsBytes`
12 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
13 |
14 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
15 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `AssertIsAsBytes`
16 = note: this error originates in the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
17
18 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
19 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
20 |
21 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
22 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
23 |
24 = help: the trait `Sized` is not implemented for `[u8]`
25 note: required by a bound in `AssertIsAsBytes`
26 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
27 |
28 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
29 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `AssertIsAsBytes`
30 = note: this error originates in the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
31
32 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
33 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
34 |
35 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
36 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
37 |
38 = help: the trait `Sized` is not implemented for `[u8]`
39 = note: all local variables must have a statically known size
40 = help: unsized locals are gated as an unstable feature
41 = note: this error originates in the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
42
43 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
44 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
45 |
46 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
47 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
48 | |
49 | doesn't have a size known at compile-time
50 | required by a bound introduced by this call
51 |
52 = help: the trait `Sized` is not implemented for `[u8]`
53 note: required by a bound in `transmute`
54 --> $RUST/core/src/intrinsics.rs
55 |
56 | pub fn transmute<Src, Dst>(src: Src) -> Dst;
57 | ^^^ required by this bound in `transmute`
58 = note: this error originates in the macro `$crate::assert_size_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
59
60 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
61 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
62 |
63 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
64 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
65 |
66 = help: the trait `Sized` is not implemented for `[u8]`
67 note: required by a bound in `AlignOf::<T>::into_t`
68 --> src/macro_util.rs
69 |
70 | impl<T> AlignOf<T> {
71 | ^ required by this bound in `AlignOf::<T>::into_t`
72 | #[inline(never)] // Make `missing_inline_in_public_items` happy.
73 | pub fn into_t(self) -> T {
74 | ------ required by a bound in this associated function
75 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
76
77 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
78 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
79 |
80 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
81 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
82 |
83 = help: the trait `Sized` is not implemented for `[u8]`
84 = note: the left-hand-side of an assignment must have a statically known size
85 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
86
87 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
88 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
89 |
90 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
91 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
92 |
93 = help: the trait `Sized` is not implemented for `[u8]`
94 note: required by a bound in `AlignOf`
95 --> src/macro_util.rs
96 |
97 | pub struct AlignOf<T> {
98 | ^ required by this bound in `AlignOf`
99 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
100
101 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
102 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
103 |
104 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
105 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
106 | |
107 | doesn't have a size known at compile-time
108 | required by a bound introduced by this call
109 |
110 = help: the trait `Sized` is not implemented for `[u8]`
111 note: required by a bound in `MaxAlignsOf::<T, U>::new`
112 --> src/macro_util.rs
113 |
114 | impl<T, U> MaxAlignsOf<T, U> {
115 | ^ required by this bound in `MaxAlignsOf::<T, U>::new`
116 | #[inline(never)] // Make `missing_inline_in_public_items` happy.
117 | pub fn new(_t: T, _u: U) -> MaxAlignsOf<T, U> {
118 | --- required by a bound in this associated function
119 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
120
121 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
122 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
123 |
124 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
125 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
126 |
127 = help: the trait `Sized` is not implemented for `[u8]`
128 note: required by a bound in `MaxAlignsOf`
129 --> src/macro_util.rs
130 |
131 | pub union MaxAlignsOf<T, U> {
132 | ^ required by this bound in `MaxAlignsOf`
133 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
134
135 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
136 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
137 |
138 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
139 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time
140 |
141 = help: the trait `Sized` is not implemented for `[u8]`
142 note: required by a bound in `AlignOf`
143 --> src/macro_util.rs
144 |
145 | pub struct AlignOf<T> {
146 | ^ required by this bound in `AlignOf`
147 = note: this error originates in the macro `$crate::assert_align_gt_eq` which comes from the expansion of the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)
148
149 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
150 --> tests/ui-stable/transmute-ref-src-unsized.rs:16:31
151 |
152 16 | const SRC_UNSIZED: &[u8; 1] = transmute_ref!(&[0u8][..]);
153 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
154 | |
155 | doesn't have a size known at compile-time
156 | required by a bound introduced by this call
157 |
158 = help: the trait `Sized` is not implemented for `[u8]`
159 note: required by a bound in `transmute_ref`
160 --> src/macro_util.rs
161 |
162 | pub const unsafe fn transmute_ref<'dst, 'src: 'dst, Src: 'src, Dst: 'dst>(
163 | ^^^ required by this bound in `transmute_ref`
164 = note: this error originates in the macro `transmute_ref` (in Nightly builds, run with -Z macro-backtrace for more info)