rust/src/test/ui/transmute/transmute-different-sizes.stderr

31 lines
903 B
Plaintext
Raw Normal View History

2018-08-08 07:28:26 -05:00
error[E0512]: transmute called with types of different sizes
2018-12-25 09:56:47 -06:00
--> $DIR/transmute-different-sizes.rs:11:17
2018-08-08 07:28:26 -05:00
|
LL | let _: i8 = transmute(16i16);
| ^^^^^^^^^
|
2018-08-10 16:46:59 -05:00
= note: source type: i16 (N bits)
= note: target type: i8 (N bits)
2018-08-08 07:28:26 -05:00
error[E0512]: transmute called with types of different sizes
2018-12-25 09:56:47 -06:00
--> $DIR/transmute-different-sizes.rs:16:17
2018-08-08 07:28:26 -05:00
|
LL | let _: i8 = transmute(x);
| ^^^^^^^^^
|
2018-08-10 16:46:59 -05:00
= note: source type: &T (N bits)
= note: target type: i8 (N bits)
2018-08-08 07:28:26 -05:00
error[E0512]: transmute called with types of different sizes
2018-12-25 09:56:47 -06:00
--> $DIR/transmute-different-sizes.rs:27:5
2018-08-08 07:28:26 -05:00
|
LL | transmute(x)
| ^^^^^^^^^
|
2018-08-10 16:46:59 -05:00
= note: source type: u16 (N bits)
2018-08-08 07:28:26 -05:00
= note: target type: <T as Specializable>::Output (this type's size can vary)
error: aborting due to 3 previous errors
For more information about this error, try `rustc --explain E0512`.