mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 07:14:28 +00:00
1ad218f3af
As our implementation of MCP411 nears completion and we begin to solicit testing, it's no longer reasonable to expect testers to type or remember `BikeshedIntrinsicFrom`. The name degrades the ease-of-reading of documentation, and the overall experience of using compiler safe transmute. Tentatively, we'll instead adopt `TransmuteFrom`. This name seems to be the one most likely to be stabilized, after discussion on Zulip [1]. We may want to revisit the ordering of `Src` and `Dst` before stabilization, at which point we'd likely consider `TransmuteInto` or `Transmute`. [1] https://rust-lang.zulipchat.com/#narrow/stream/216762-project-safe-transmute/topic/What.20should.20.60BikeshedIntrinsicFrom.60.20be.20named.3F
117 lines
4.3 KiB
Plaintext
117 lines
4.3 KiB
Plaintext
error[E0080]: evaluation of constant value failed
|
|
--> $DIR/uninhabited.rs:41:9
|
|
|
|
|
LL | assert!(false);
|
|
| ^^^^^^^^^^^^^^ the evaluated program panicked at 'assertion failed: false', $DIR/uninhabited.rs:41:9
|
|
|
|
|
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error[E0080]: evaluation of constant value failed
|
|
--> $DIR/uninhabited.rs:63:9
|
|
|
|
|
LL | assert!(false);
|
|
| ^^^^^^^^^^^^^^ the evaluated program panicked at 'assertion failed: false', $DIR/uninhabited.rs:63:9
|
|
|
|
|
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error[E0080]: evaluation of constant value failed
|
|
--> $DIR/uninhabited.rs:87:9
|
|
|
|
|
LL | assert!(false);
|
|
| ^^^^^^^^^^^^^^ the evaluated program panicked at 'assertion failed: false', $DIR/uninhabited.rs:87:9
|
|
|
|
|
= note: this error originates in the macro `assert` (in Nightly builds, run with -Z macro-backtrace for more info)
|
|
|
|
error[E0277]: `()` cannot be safely transmuted into `void::Void`
|
|
--> $DIR/uninhabited.rs:29:41
|
|
|
|
|
LL | assert::is_maybe_transmutable::<(), Void>();
|
|
| ^^^^ `void::Void` is uninhabited
|
|
|
|
|
note: required by a bound in `is_maybe_transmutable`
|
|
--> $DIR/uninhabited.rs:10:14
|
|
|
|
|
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
|
| --------------------- required by a bound in this function
|
|
LL | where
|
|
LL | Dst: TransmuteFrom<Src, {
|
|
| ______________^
|
|
LL | | Assume {
|
|
LL | | alignment: true,
|
|
LL | | lifetimes: true,
|
|
... |
|
|
LL | | }
|
|
LL | | }>
|
|
| |__________^ required by this bound in `is_maybe_transmutable`
|
|
|
|
error[E0277]: `()` cannot be safely transmuted into `yawning_void_struct::Void`
|
|
--> $DIR/uninhabited.rs:49:41
|
|
|
|
|
LL | assert::is_maybe_transmutable::<(), Void>();
|
|
| ^^^^ `yawning_void_struct::Void` is uninhabited
|
|
|
|
|
note: required by a bound in `is_maybe_transmutable`
|
|
--> $DIR/uninhabited.rs:10:14
|
|
|
|
|
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
|
| --------------------- required by a bound in this function
|
|
LL | where
|
|
LL | Dst: TransmuteFrom<Src, {
|
|
| ______________^
|
|
LL | | Assume {
|
|
LL | | alignment: true,
|
|
LL | | lifetimes: true,
|
|
... |
|
|
LL | | }
|
|
LL | | }>
|
|
| |__________^ required by this bound in `is_maybe_transmutable`
|
|
|
|
error[E0277]: `()` cannot be safely transmuted into `yawning_void_enum::Void`
|
|
--> $DIR/uninhabited.rs:71:41
|
|
|
|
|
LL | assert::is_maybe_transmutable::<(), Void>();
|
|
| ^^^^ `yawning_void_enum::Void` is uninhabited
|
|
|
|
|
note: required by a bound in `is_maybe_transmutable`
|
|
--> $DIR/uninhabited.rs:10:14
|
|
|
|
|
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
|
| --------------------- required by a bound in this function
|
|
LL | where
|
|
LL | Dst: TransmuteFrom<Src, {
|
|
| ______________^
|
|
LL | | Assume {
|
|
LL | | alignment: true,
|
|
LL | | lifetimes: true,
|
|
... |
|
|
LL | | }
|
|
LL | | }>
|
|
| |__________^ required by this bound in `is_maybe_transmutable`
|
|
|
|
error[E0277]: `u128` cannot be safely transmuted into `DistantVoid`
|
|
--> $DIR/uninhabited.rs:92:43
|
|
|
|
|
LL | assert::is_maybe_transmutable::<u128, DistantVoid>();
|
|
| ^^^^^^^^^^^ at least one value of `u128` isn't a bit-valid value of `DistantVoid`
|
|
|
|
|
note: required by a bound in `is_maybe_transmutable`
|
|
--> $DIR/uninhabited.rs:10:14
|
|
|
|
|
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
|
| --------------------- required by a bound in this function
|
|
LL | where
|
|
LL | Dst: TransmuteFrom<Src, {
|
|
| ______________^
|
|
LL | | Assume {
|
|
LL | | alignment: true,
|
|
LL | | lifetimes: true,
|
|
... |
|
|
LL | | }
|
|
LL | | }>
|
|
| |__________^ required by this bound in `is_maybe_transmutable`
|
|
|
|
error: aborting due to 7 previous errors
|
|
|
|
Some errors have detailed explanations: E0080, E0277.
|
|
For more information about an error, try `rustc --explain E0080`.
|