]> git.lizzy.rs Git - rust.git/blob - src/test/ui/transmute/transmute-different-sizes.stderr
Rollup merge of #101388 - compiler-errors:issue-101376, r=fee1-dead
[rust.git] / src / test / ui / transmute / transmute-different-sizes.stderr
1 error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
2   --> $DIR/transmute-different-sizes.rs:11:17
3    |
4 LL |     let _: i8 = transmute(16i16);
5    |                 ^^^^^^^^^
6    |
7    = note: source type: `i16` (N bits)
8    = note: target type: `i8` (N bits)
9
10 error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
11   --> $DIR/transmute-different-sizes.rs:16:17
12    |
13 LL |     let _: i8 = transmute(x);
14    |                 ^^^^^^^^^
15    |
16    = note: source type: `&T` (N bits)
17    = note: target type: `i8` (N bits)
18
19 error[E0512]: cannot transmute between types of different sizes, or dependently-sized types
20   --> $DIR/transmute-different-sizes.rs:27:5
21    |
22 LL |     transmute(x)
23    |     ^^^^^^^^^
24    |
25    = note: source type: `u16` (N bits)
26    = note: target type: `<T as Specializable>::Output` (this type does not have a fixed size)
27
28 error: aborting due to 3 previous errors
29
30 For more information about this error, try `rustc --explain E0512`.