mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-02 00:07:42 +03:00
safe transmute: use Assume struct to provide analysis options
This was left as a TODO in #92268, and brings the trait more in line with what was defined in MCP411. `Assume::visibility` has been renamed to `Assume::safety`, as library safety is what's actually being assumed; visibility is just the mechanism by which it is currently checked (this may change). ref: https://github.com/rust-lang/compiler-team/issues/411 ref: https://github.com/rust-lang/rust/issues/99571
This commit is contained in:
@@ -4581,6 +4581,7 @@ version = "0.1.0"
|
||||
dependencies = [
|
||||
"itertools",
|
||||
"rustc_data_structures",
|
||||
"rustc_hir",
|
||||
"rustc_infer",
|
||||
"rustc_macros",
|
||||
"rustc_middle",
|
||||
|
||||
@@ -192,7 +192,8 @@ pub fn extract(attrs: &[ast::Attribute]) -> Option<(Symbol, Span)> {
|
||||
DispatchFromDyn, sym::dispatch_from_dyn, dispatch_from_dyn_trait, Target::Trait, GenericRequirement::Minimum(1);
|
||||
|
||||
// language items relating to transmutability
|
||||
TransmuteTrait, sym::transmute_trait, transmute_trait, Target::Trait, GenericRequirement::Exact(6);
|
||||
TransmuteOpts, sym::transmute_opts, transmute_opts, Target::Struct, GenericRequirement::Exact(0);
|
||||
TransmuteTrait, sym::transmute_trait, transmute_trait, Target::Trait, GenericRequirement::Exact(3);
|
||||
|
||||
Add(Op), sym::add, add_trait, Target::Trait, GenericRequirement::Exact(1);
|
||||
Sub(Op), sym::sub, sub_trait, Target::Trait, GenericRequirement::Exact(1);
|
||||
|
||||
@@ -334,6 +334,7 @@
|
||||
alias,
|
||||
align,
|
||||
align_offset,
|
||||
alignment,
|
||||
alignstack,
|
||||
all,
|
||||
alloc,
|
||||
@@ -859,6 +860,7 @@
|
||||
lib,
|
||||
libc,
|
||||
lifetime,
|
||||
lifetimes,
|
||||
likely,
|
||||
line,
|
||||
line_macro,
|
||||
@@ -1284,6 +1286,7 @@
|
||||
rustfmt,
|
||||
rvalue_static_promotion,
|
||||
s,
|
||||
safety,
|
||||
sanitize,
|
||||
sanitizer_runtime,
|
||||
saturating_add,
|
||||
@@ -1466,6 +1469,7 @@
|
||||
trait_alias,
|
||||
trait_upcasting,
|
||||
transmute,
|
||||
transmute_opts,
|
||||
transmute_trait,
|
||||
transparent,
|
||||
transparent_enums,
|
||||
@@ -1560,6 +1564,7 @@
|
||||
va_list,
|
||||
va_start,
|
||||
val,
|
||||
validity,
|
||||
values,
|
||||
var,
|
||||
variant_count,
|
||||
|
||||
@@ -279,29 +279,17 @@ fn confirm_transmutability_candidate(
|
||||
let predicate = obligation.predicate;
|
||||
|
||||
let type_at = |i| predicate.map_bound(|p| p.trait_ref.substs.type_at(i));
|
||||
let bool_at = |i| {
|
||||
predicate
|
||||
.skip_binder()
|
||||
.trait_ref
|
||||
.substs
|
||||
.const_at(i)
|
||||
.try_eval_bool(self.tcx(), obligation.param_env)
|
||||
.unwrap_or(true)
|
||||
};
|
||||
let const_at = |i| predicate.skip_binder().trait_ref.substs.const_at(i);
|
||||
|
||||
let src_and_dst = predicate.map_bound(|p| rustc_transmute::Types {
|
||||
src: p.trait_ref.substs.type_at(1),
|
||||
dst: p.trait_ref.substs.type_at(0),
|
||||
src: p.trait_ref.substs.type_at(1),
|
||||
});
|
||||
|
||||
let scope = type_at(2).skip_binder();
|
||||
|
||||
let assume = rustc_transmute::Assume {
|
||||
alignment: bool_at(3),
|
||||
lifetimes: bool_at(4),
|
||||
validity: bool_at(5),
|
||||
visibility: bool_at(6),
|
||||
};
|
||||
let assume =
|
||||
rustc_transmute::Assume::from_const(self.infcx.tcx, obligation.param_env, const_at(3));
|
||||
|
||||
let cause = obligation.cause.clone();
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ edition = "2021"
|
||||
[dependencies]
|
||||
tracing = "0.1"
|
||||
rustc_data_structures = { path = "../rustc_data_structures", optional = true}
|
||||
rustc_hir = { path = "../rustc_hir", optional = true}
|
||||
rustc_infer = { path = "../rustc_infer", optional = true}
|
||||
rustc_macros = { path = "../rustc_macros", optional = true}
|
||||
rustc_middle = { path = "../rustc_middle", optional = true}
|
||||
@@ -18,6 +19,7 @@ rustc_target = { path = "../rustc_target", optional = true}
|
||||
rustc = [
|
||||
"rustc_middle",
|
||||
"rustc_data_structures",
|
||||
"rustc_hir",
|
||||
"rustc_infer",
|
||||
"rustc_macros",
|
||||
"rustc_span",
|
||||
|
||||
@@ -26,8 +26,8 @@
|
||||
pub struct Assume {
|
||||
pub alignment: bool,
|
||||
pub lifetimes: bool,
|
||||
pub safety: bool,
|
||||
pub validity: bool,
|
||||
pub visibility: bool,
|
||||
}
|
||||
|
||||
/// The type encodes answers to the question: "Are these types transmutable?"
|
||||
@@ -69,11 +69,17 @@ pub enum Reason {
|
||||
|
||||
#[cfg(feature = "rustc")]
|
||||
mod rustc {
|
||||
use super::*;
|
||||
|
||||
use rustc_hir::lang_items::LangItem;
|
||||
use rustc_infer::infer::InferCtxt;
|
||||
use rustc_macros::{TypeFoldable, TypeVisitable};
|
||||
use rustc_middle::traits::ObligationCause;
|
||||
use rustc_middle::ty::Binder;
|
||||
use rustc_middle::ty::Const;
|
||||
use rustc_middle::ty::ParamEnv;
|
||||
use rustc_middle::ty::Ty;
|
||||
use rustc_middle::ty::TyCtxt;
|
||||
|
||||
/// The source and destination types of a transmutation.
|
||||
#[derive(TypeFoldable, TypeVisitable, Debug, Clone, Copy)]
|
||||
@@ -113,6 +119,57 @@ pub fn is_transmutable(
|
||||
.answer()
|
||||
}
|
||||
}
|
||||
|
||||
impl Assume {
|
||||
/// Constructs an `Assume` from a given const-`Assume`.
|
||||
pub fn from_const<'tcx>(
|
||||
tcx: TyCtxt<'tcx>,
|
||||
param_env: ParamEnv<'tcx>,
|
||||
c: Const<'tcx>,
|
||||
) -> Self {
|
||||
use rustc_middle::ty::DestructuredConst;
|
||||
use rustc_middle::ty::TypeVisitable;
|
||||
use rustc_span::symbol::sym;
|
||||
|
||||
let c = c.eval(tcx, param_env);
|
||||
|
||||
if let Some(err) = c.error_reported() {
|
||||
return Self { alignment: true, lifetimes: true, safety: true, validity: true };
|
||||
}
|
||||
|
||||
let adt_def = c.ty().ty_adt_def().expect("The given `Const` must be an ADT.");
|
||||
|
||||
assert_eq!(
|
||||
tcx.require_lang_item(LangItem::TransmuteOpts, None),
|
||||
adt_def.did(),
|
||||
"The given `Const` was not marked with the `{}` lang item.",
|
||||
LangItem::TransmuteOpts.name(),
|
||||
);
|
||||
|
||||
let DestructuredConst { variant, fields } = tcx.destructure_const(c);
|
||||
let variant_idx = variant.expect("The given `Const` must be an ADT.");
|
||||
let variant = adt_def.variant(variant_idx);
|
||||
|
||||
let get_field = |name| {
|
||||
let (field_idx, _) = variant
|
||||
.fields
|
||||
.iter()
|
||||
.enumerate()
|
||||
.find(|(_, field_def)| name == field_def.name)
|
||||
.expect(&format!("There were no fields named `{name}`."));
|
||||
fields[field_idx].try_eval_bool(tcx, param_env).expect(&format!(
|
||||
"The field named `{name}` lang item could not be evaluated to a bool."
|
||||
))
|
||||
};
|
||||
|
||||
Self {
|
||||
alignment: get_field(sym::alignment),
|
||||
lifetimes: get_field(sym::lifetimes),
|
||||
safety: get_field(sym::safety),
|
||||
validity: get_field(sym::validity),
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "rustc")]
|
||||
|
||||
@@ -105,7 +105,7 @@ impl<C> MaybeTransmutableQuery<Tree<<C as QueryContext>::Def, <C as QueryContext
|
||||
#[inline(always)]
|
||||
#[instrument(level = "debug", skip(self), fields(src = ?self.src, dst = ?self.dst))]
|
||||
pub(crate) fn answer(self) -> Answer<<C as QueryContext>::Ref> {
|
||||
let assume_visibility = self.assume.visibility;
|
||||
let assume_visibility = self.assume.safety;
|
||||
let query_or_answer = self.map_layouts(|src, dst, scope, context| {
|
||||
// Remove all `Def` nodes from `src`, without checking their visibility.
|
||||
let src = src.prune(&|def| true);
|
||||
|
||||
@@ -13,7 +13,7 @@ fn should_permit_identity_transmutation_tree() {
|
||||
layout::Tree::<Def, !>::bool(),
|
||||
layout::Tree::<Def, !>::bool(),
|
||||
(),
|
||||
crate::Assume { alignment: false, lifetimes: false, validity: true, visibility: false },
|
||||
crate::Assume { alignment: false, lifetimes: false, validity: true, safety: false },
|
||||
UltraMinimal,
|
||||
)
|
||||
.answer();
|
||||
@@ -26,7 +26,7 @@ fn should_permit_identity_transmutation_dfa() {
|
||||
layout::Dfa::<!>::bool(),
|
||||
layout::Dfa::<!>::bool(),
|
||||
(),
|
||||
crate::Assume { alignment: false, lifetimes: false, validity: true, visibility: false },
|
||||
crate::Assume { alignment: false, lifetimes: false, validity: true, safety: false },
|
||||
UltraMinimal,
|
||||
)
|
||||
.answer();
|
||||
|
||||
@@ -93,6 +93,7 @@
|
||||
#![warn(missing_debug_implementations)]
|
||||
#![warn(missing_docs)]
|
||||
#![allow(explicit_outlives_requirements)]
|
||||
#![allow(incomplete_features)]
|
||||
//
|
||||
// Library features:
|
||||
#![feature(const_align_offset)]
|
||||
@@ -160,6 +161,7 @@
|
||||
//
|
||||
// Language features:
|
||||
#![feature(abi_unadjusted)]
|
||||
#![feature(adt_const_params)]
|
||||
#![feature(allow_internal_unsafe)]
|
||||
#![feature(allow_internal_unstable)]
|
||||
#![feature(associated_type_bounds)]
|
||||
|
||||
@@ -4,25 +4,20 @@
|
||||
/// any value of type `Self` are safely transmutable into a value of type `Dst`, in a given `Context`,
|
||||
/// notwithstanding whatever safety checks you have asked the compiler to [`Assume`] are satisfied.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
#[lang = "transmute_trait"]
|
||||
#[cfg_attr(not(bootstrap), lang = "transmute_trait")]
|
||||
#[rustc_on_unimplemented(
|
||||
message = "`{Src}` cannot be safely transmuted into `{Self}` in the defining scope of `{Context}`.",
|
||||
label = "`{Src}` cannot be safely transmuted into `{Self}` in the defining scope of `{Context}`."
|
||||
)]
|
||||
pub unsafe trait BikeshedIntrinsicFrom<
|
||||
Src,
|
||||
Context,
|
||||
const ASSUME_ALIGNMENT: bool,
|
||||
const ASSUME_LIFETIMES: bool,
|
||||
const ASSUME_VALIDITY: bool,
|
||||
const ASSUME_VISIBILITY: bool,
|
||||
> where
|
||||
pub unsafe trait BikeshedIntrinsicFrom<Src, Context, const ASSUME: Assume = { Assume::NOTHING }>
|
||||
where
|
||||
Src: ?Sized,
|
||||
{
|
||||
}
|
||||
|
||||
/// What transmutation safety conditions shall the compiler assume that *you* are checking?
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
#[cfg_attr(not(bootstrap), lang = "transmute_opts")]
|
||||
#[derive(PartialEq, Eq, Clone, Copy, Debug)]
|
||||
pub struct Assume {
|
||||
/// When `true`, the compiler assumes that *you* are ensuring (either dynamically or statically) that
|
||||
@@ -33,11 +28,80 @@ pub struct Assume {
|
||||
/// that violates Rust's memory model.
|
||||
pub lifetimes: bool,
|
||||
|
||||
/// When `true`, the compiler assumes that *you* have ensured that it is safe for you to violate the
|
||||
/// type and field privacy of the destination type (and sometimes of the source type, too).
|
||||
pub safety: bool,
|
||||
|
||||
/// When `true`, the compiler assumes that *you* are ensuring that the source type is actually a valid
|
||||
/// instance of the destination type.
|
||||
pub validity: bool,
|
||||
|
||||
/// When `true`, the compiler assumes that *you* have ensured that it is safe for you to violate the
|
||||
/// type and field privacy of the destination type (and sometimes of the source type, too).
|
||||
pub visibility: bool,
|
||||
}
|
||||
|
||||
impl Assume {
|
||||
/// Do not assume that *you* have ensured any safety properties are met.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const NOTHING: Self =
|
||||
Self { alignment: false, lifetimes: false, safety: false, validity: false };
|
||||
|
||||
/// Assume only that alignment conditions are met.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const ALIGNMENT: Self = Self { alignment: true, ..Self::NOTHING };
|
||||
|
||||
/// Assume only that lifetime conditions are met.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const LIFETIMES: Self = Self { lifetimes: true, ..Self::NOTHING };
|
||||
|
||||
/// Assume only that safety conditions are met.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const SAFETY: Self = Self { safety: true, ..Self::NOTHING };
|
||||
|
||||
/// Assume only that dynamically-satisfiable validity conditions are met.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const VALIDITY: Self = Self { validity: true, ..Self::NOTHING };
|
||||
|
||||
/// Assume both `self` and `other_assumptions`.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const fn and(self, other_assumptions: Self) -> Self {
|
||||
Self {
|
||||
alignment: self.alignment || other_assumptions.alignment,
|
||||
lifetimes: self.lifetimes || other_assumptions.lifetimes,
|
||||
safety: self.safety || other_assumptions.safety,
|
||||
validity: self.validity || other_assumptions.validity,
|
||||
}
|
||||
}
|
||||
|
||||
/// Assume `self`, excepting `other_assumptions`.
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
pub const fn but_not(self, other_assumptions: Self) -> Self {
|
||||
Self {
|
||||
alignment: self.alignment && !other_assumptions.alignment,
|
||||
lifetimes: self.lifetimes && !other_assumptions.lifetimes,
|
||||
safety: self.safety && !other_assumptions.safety,
|
||||
validity: self.validity && !other_assumptions.validity,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// FIXME(jswrenn): This const op is not actually usable. Why?
|
||||
// https://github.com/rust-lang/rust/pull/100726#issuecomment-1219928926
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
#[rustc_const_unstable(feature = "transmutability", issue = "99571")]
|
||||
impl const core::ops::Add for Assume {
|
||||
type Output = Assume;
|
||||
|
||||
fn add(self, other_assumptions: Assume) -> Assume {
|
||||
self.and(other_assumptions)
|
||||
}
|
||||
}
|
||||
|
||||
// FIXME(jswrenn): This const op is not actually usable. Why?
|
||||
// https://github.com/rust-lang/rust/pull/100726#issuecomment-1219928926
|
||||
#[unstable(feature = "transmutability", issue = "99571")]
|
||||
#[rustc_const_unstable(feature = "transmutability", issue = "99571")]
|
||||
impl const core::ops::Sub for Assume {
|
||||
type Output = Assume;
|
||||
|
||||
fn sub(self, other_assumptions: Assume) -> Assume {
|
||||
self.but_not(other_assumptions)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
//! provided indirectly through an abstraction.
|
||||
|
||||
#![crate_type = "lib"]
|
||||
#![feature(adt_const_params)]
|
||||
#![feature(transmutability)]
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
@@ -13,19 +14,13 @@ pub fn is_transmutable<
|
||||
Src,
|
||||
Dst,
|
||||
Context,
|
||||
const ASSUME_ALIGNMENT: bool,
|
||||
const ASSUME_LIFETIMES: bool,
|
||||
const ASSUME_VALIDITY: bool,
|
||||
const ASSUME_VISIBILITY: bool,
|
||||
const ASSUME: std::mem::Assume,
|
||||
>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<
|
||||
Src,
|
||||
Context,
|
||||
ASSUME_ALIGNMENT,
|
||||
ASSUME_LIFETIMES,
|
||||
ASSUME_VALIDITY,
|
||||
ASSUME_VISIBILITY,
|
||||
ASSUME,
|
||||
>,
|
||||
{}
|
||||
}
|
||||
@@ -35,7 +30,7 @@ fn direct() {
|
||||
#[repr(C)] struct Src;
|
||||
#[repr(C)] struct Dst;
|
||||
|
||||
assert::is_transmutable::<Src, Dst, Context, false, false, false, false>();
|
||||
assert::is_transmutable::<Src, Dst, Context, { std::mem::Assume::NOTHING }>();
|
||||
}
|
||||
|
||||
fn via_const() {
|
||||
@@ -45,7 +40,7 @@ fn via_const() {
|
||||
|
||||
const FALSE: bool = false;
|
||||
|
||||
assert::is_transmutable::<Src, Dst, Context, FALSE, FALSE, FALSE, FALSE>();
|
||||
assert::is_transmutable::<Src, Dst, Context, { std::mem::Assume::NOTHING }>();
|
||||
}
|
||||
|
||||
fn via_associated_const() {
|
||||
@@ -65,9 +60,13 @@ impl Trait for Ty {}
|
||||
Src,
|
||||
Dst,
|
||||
Context,
|
||||
{Ty::FALSE},
|
||||
{Ty::FALSE},
|
||||
{Ty::FALSE},
|
||||
{Ty::FALSE}
|
||||
{
|
||||
std::mem::Assume {
|
||||
alignment: {Ty::FALSE},
|
||||
lifetimes: {Ty::FALSE},
|
||||
safety: {Ty::FALSE},
|
||||
validity: {Ty::FALSE},
|
||||
}
|
||||
}
|
||||
>();
|
||||
}
|
||||
|
||||
@@ -6,13 +6,13 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn array_like<T, E, const N: usize>()
|
||||
where
|
||||
T: BikeshedIntrinsicFrom<[E; N], Context, false, false, false, true>,
|
||||
[E; N]: BikeshedIntrinsicFrom<T, Context, false, false, false, true>
|
||||
T: BikeshedIntrinsicFrom<[E; N], Context, { Assume::SAFETY }>,
|
||||
[E; N]: BikeshedIntrinsicFrom<T, Context, { Assume::SAFETY }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,12 +6,12 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,12 +6,17 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,17 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,98 +1,134 @@
|
||||
error[E0277]: `[String; 0]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:21:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:26:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `[String; 0]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 0], assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 0], assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `u128` cannot be safely transmuted into `[String; 0]` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:22:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:27:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `[String; 0]` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `[String; 0]`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `[String; 0]`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `[String; 1]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:27:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:32:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `[String; 1]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 1], assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 1], assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `u128` cannot be safely transmuted into `[String; 1]` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:28:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:33:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `[String; 1]` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `[String; 1]`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `[String; 1]`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `[String; 2]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:33:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:38:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `[String; 2]` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 2], assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<[String; 2], assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `u128` cannot be safely transmuted into `[String; 2]` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:34:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:39:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `[String; 2]` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `[String; 2]`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `[String; 2]`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to 6 previous errors
|
||||
|
||||
|
||||
+9
-2
@@ -5,11 +5,18 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+280
-140
@@ -1,322 +1,462 @@
|
||||
error[E0277]: `Zst` cannot be safely transmuted into `V0i8` in the defining scope of `n8::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:41:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:48:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `Zst` cannot be safely transmuted into `V0i8` in the defining scope of `n8::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Zst, n8::Context, true, true, true, true>` is not implemented for `V0i8`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Zst, n8::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0i8`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0i8` cannot be safely transmuted into `u16` in the defining scope of `n8::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:43:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:50:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0i8` cannot be safely transmuted into `u16` in the defining scope of `n8::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i8, n8::Context, true, true, true, true>` is not implemented for `u16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i8, n8::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `Zst` cannot be safely transmuted into `V0u8` in the defining scope of `n8::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:49:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:56:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `Zst` cannot be safely transmuted into `V0u8` in the defining scope of `n8::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Zst, n8::Context, true, true, true, true>` is not implemented for `V0u8`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Zst, n8::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0u8`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0u8` cannot be safely transmuted into `u16` in the defining scope of `n8::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:51:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:58:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0u8` cannot be safely transmuted into `u16` in the defining scope of `n8::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u8, n8::Context, true, true, true, true>` is not implemented for `u16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u8, n8::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `V0i16` in the defining scope of `n16::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:65:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:72:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u8` cannot be safely transmuted into `V0i16` in the defining scope of `n16::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, n16::Context, true, true, true, true>` is not implemented for `V0i16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, n16::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0i16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0i16` cannot be safely transmuted into `u32` in the defining scope of `n16::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:67:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:74:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0i16` cannot be safely transmuted into `u32` in the defining scope of `n16::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i16, n16::Context, true, true, true, true>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i16, n16::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `V0u16` in the defining scope of `n16::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:73:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:80:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u8` cannot be safely transmuted into `V0u16` in the defining scope of `n16::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, n16::Context, true, true, true, true>` is not implemented for `V0u16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, n16::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0u16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0u16` cannot be safely transmuted into `u32` in the defining scope of `n16::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:75:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:82:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0u16` cannot be safely transmuted into `u32` in the defining scope of `n16::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u16, n16::Context, true, true, true, true>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u16, n16::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `V0i32` in the defining scope of `n32::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:89:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:96:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u16` cannot be safely transmuted into `V0i32` in the defining scope of `n32::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, n32::Context, true, true, true, true>` is not implemented for `V0i32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, n32::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0i32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0i32` cannot be safely transmuted into `u64` in the defining scope of `n32::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:91:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:98:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0i32` cannot be safely transmuted into `u64` in the defining scope of `n32::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i32, n32::Context, true, true, true, true>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i32, n32::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `V0u32` in the defining scope of `n32::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:97:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:104:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u16` cannot be safely transmuted into `V0u32` in the defining scope of `n32::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, n32::Context, true, true, true, true>` is not implemented for `V0u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, n32::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0u32` cannot be safely transmuted into `u64` in the defining scope of `n32::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:99:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:106:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0u32` cannot be safely transmuted into `u64` in the defining scope of `n32::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u32, n32::Context, true, true, true, true>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u32, n32::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `V0i64` in the defining scope of `n64::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:113:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:120:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u32` cannot be safely transmuted into `V0i64` in the defining scope of `n64::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, n64::Context, true, true, true, true>` is not implemented for `V0i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, n64::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0i64` cannot be safely transmuted into `u128` in the defining scope of `n64::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:115:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:122:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0i64` cannot be safely transmuted into `u128` in the defining scope of `n64::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i64, n64::Context, true, true, true, true>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0i64, n64::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `V0u64` in the defining scope of `n64::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:121:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:128:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u32` cannot be safely transmuted into `V0u64` in the defining scope of `n64::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, n64::Context, true, true, true, true>` is not implemented for `V0u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, n64::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0u64` cannot be safely transmuted into `u128` in the defining scope of `n64::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:123:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:130:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0u64` cannot be safely transmuted into `u128` in the defining scope of `n64::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u64, n64::Context, true, true, true, true>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0u64, n64::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `V0isize` in the defining scope of `nsize::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:137:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:144:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u8` cannot be safely transmuted into `V0isize` in the defining scope of `nsize::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, nsize::Context, true, true, true, true>` is not implemented for `V0isize`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, nsize::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0isize`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0isize` cannot be safely transmuted into `[usize; 2]` in the defining scope of `nsize::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:139:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:146:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0isize` cannot be safely transmuted into `[usize; 2]` in the defining scope of `nsize::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0isize, nsize::Context, true, true, true, true>` is not implemented for `[usize; 2]`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0isize, nsize::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `[usize; 2]`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `V0usize` in the defining scope of `nsize::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:145:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:152:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Smaller, Current, Context>();
|
||||
| ^^^^^^^ `u8` cannot be safely transmuted into `V0usize` in the defining scope of `nsize::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, nsize::Context, true, true, true, true>` is not implemented for `V0usize`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, nsize::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `V0usize`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `V0usize` cannot be safely transmuted into `[usize; 2]` in the defining scope of `nsize::Context`.
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:147:44
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:154:44
|
||||
|
|
||||
LL | assert::is_transmutable::<Current, Larger, Context>();
|
||||
| ^^^^^^ `V0usize` cannot be safely transmuted into `[usize; 2]` in the defining scope of `nsize::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0usize, nsize::Context, true, true, true, true>` is not implemented for `[usize; 2]`
|
||||
= help: the trait `BikeshedIntrinsicFrom<V0usize, nsize::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `[usize; 2]`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/primitive_reprs_should_have_correct_length.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to 20 previous errors
|
||||
|
||||
|
||||
@@ -6,12 +6,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,98 +1,140 @@
|
||||
error[E0277]: `void::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:21:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:28:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `void::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<void::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<void::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `void::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:22:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:29:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `void::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `void::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `void::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `singleton::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:27:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:34:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `singleton::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<singleton::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<singleton::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `singleton::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:28:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:35:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `singleton::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `singleton::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `singleton::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `duplex::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:33:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:40:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `duplex::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<duplex::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<duplex::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `duplex::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:34:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:41:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `duplex::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `duplex::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `duplex::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:14:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to 6 previous errors
|
||||
|
||||
|
||||
@@ -7,12 +7,17 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,11 +6,16 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `should_pad_variants::Context`.
|
||||
--> $DIR/should_pad_variants.rs:39:36
|
||||
--> $DIR/should_pad_variants.rs:44:36
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context>();
|
||||
| ^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `should_pad_variants::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, should_pad_variants::Context, true, true, true, true>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, should_pad_variants::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_pad_variants.rs:13:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -7,12 +7,17 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Unexpected` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_respect_endianness.rs:32:36
|
||||
--> $DIR/should_respect_endianness.rs:37:36
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Unexpected>();
|
||||
| ^^^^^^^^^^ `Src` cannot be safely transmuted into `Unexpected` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, assert::Context, true, true, true, true>` is not implemented for `Unexpected`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `Unexpected`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_respect_endianness.rs:15:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -2,11 +2,13 @@
|
||||
//! provided.
|
||||
|
||||
#![crate_type = "lib"]
|
||||
#![feature(adt_const_params)]
|
||||
#![feature(generic_const_exprs)]
|
||||
#![feature(transmutability)]
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<
|
||||
Src,
|
||||
@@ -14,19 +16,34 @@ pub fn is_transmutable<
|
||||
Context,
|
||||
const ASSUME_ALIGNMENT: bool,
|
||||
const ASSUME_LIFETIMES: bool,
|
||||
const ASSUME_SAFETY: bool,
|
||||
const ASSUME_VALIDITY: bool,
|
||||
const ASSUME_VISIBILITY: bool,
|
||||
>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<
|
||||
Src,
|
||||
Context,
|
||||
ASSUME_ALIGNMENT,
|
||||
ASSUME_LIFETIMES,
|
||||
ASSUME_VALIDITY,
|
||||
ASSUME_VISIBILITY,
|
||||
{ from_options(ASSUME_ALIGNMENT, ASSUME_LIFETIMES, ASSUME_SAFETY, ASSUME_VALIDITY) }
|
||||
//~^ ERROR E0080
|
||||
//~| ERROR E0080
|
||||
//~| ERROR E0080
|
||||
//~| ERROR E0080
|
||||
>,
|
||||
{}
|
||||
|
||||
const fn from_options(
|
||||
alignment: bool,
|
||||
lifetimes: bool,
|
||||
safety: bool,
|
||||
validity: bool,
|
||||
) -> Assume {
|
||||
Assume {
|
||||
alignment,
|
||||
lifetimes,
|
||||
safety,
|
||||
validity,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn test() {
|
||||
|
||||
+31
-6
@@ -1,27 +1,52 @@
|
||||
error[E0308]: mismatched types
|
||||
--> $DIR/wrong-type-assume.rs:36:51
|
||||
--> $DIR/wrong-type-assume.rs:53:51
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context, {0u8}, false, false, false>();
|
||||
| ^^^ expected `bool`, found `u8`
|
||||
|
||||
error[E0080]: evaluation of `assert::is_transmutable::<test::Src, test::Dst, test::Context, {0u8}, false, false, false>::{constant#0}` failed
|
||||
--> $DIR/wrong-type-assume.rs:26:15
|
||||
|
|
||||
LL | { from_options(ASSUME_ALIGNMENT, ASSUME_LIFETIMES, ASSUME_SAFETY, ASSUME_VALIDITY) }
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
|
||||
|
||||
error[E0308]: mismatched types
|
||||
--> $DIR/wrong-type-assume.rs:37:58
|
||||
--> $DIR/wrong-type-assume.rs:54:58
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context, false, {0u8}, false, false>();
|
||||
| ^^^ expected `bool`, found `u8`
|
||||
|
||||
error[E0080]: evaluation of `assert::is_transmutable::<test::Src, test::Dst, test::Context, false, {0u8}, false, false>::{constant#0}` failed
|
||||
--> $DIR/wrong-type-assume.rs:26:15
|
||||
|
|
||||
LL | { from_options(ASSUME_ALIGNMENT, ASSUME_LIFETIMES, ASSUME_SAFETY, ASSUME_VALIDITY) }
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
|
||||
|
||||
error[E0308]: mismatched types
|
||||
--> $DIR/wrong-type-assume.rs:38:65
|
||||
--> $DIR/wrong-type-assume.rs:55:65
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context, false, false, {0u8}, false>();
|
||||
| ^^^ expected `bool`, found `u8`
|
||||
|
||||
error[E0080]: evaluation of `assert::is_transmutable::<test::Src, test::Dst, test::Context, false, false, {0u8}, false>::{constant#0}` failed
|
||||
--> $DIR/wrong-type-assume.rs:26:15
|
||||
|
|
||||
LL | { from_options(ASSUME_ALIGNMENT, ASSUME_LIFETIMES, ASSUME_SAFETY, ASSUME_VALIDITY) }
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
|
||||
|
||||
error[E0308]: mismatched types
|
||||
--> $DIR/wrong-type-assume.rs:39:72
|
||||
--> $DIR/wrong-type-assume.rs:56:72
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context, false, false, false, {0u8}>();
|
||||
| ^^^ expected `bool`, found `u8`
|
||||
|
||||
error: aborting due to 4 previous errors
|
||||
error[E0080]: evaluation of `assert::is_transmutable::<test::Src, test::Dst, test::Context, false, false, false, {0u8}>::{constant#0}` failed
|
||||
--> $DIR/wrong-type-assume.rs:26:15
|
||||
|
|
||||
LL | { from_options(ASSUME_ALIGNMENT, ASSUME_LIFETIMES, ASSUME_SAFETY, ASSUME_VALIDITY) }
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ referenced constant has errors
|
||||
|
||||
For more information about this error, try `rustc --explain E0308`.
|
||||
error: aborting due to 8 previous errors
|
||||
|
||||
Some errors have detailed explanations: E0080, E0308.
|
||||
For more information about an error, try `rustc --explain E0080`.
|
||||
|
||||
@@ -4,17 +4,17 @@
|
||||
#![allow(incomplete_features)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
{}
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,15 +4,15 @@ error[E0277]: `u8` cannot be safely transmuted into `bool` in the defining scope
|
||||
LL | assert::is_transmutable::<u8, bool>();
|
||||
| ^^^^ `u8` cannot be safely transmuted into `bool` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, true>` is not implemented for `bool`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: false }>` is not implemented for `bool`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/bool.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,15 +4,15 @@ error[E0277]: `i8` cannot be safely transmuted into `i16` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, i16>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `i16` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `i16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `u16` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:63:40
|
||||
@@ -20,15 +20,15 @@ error[E0277]: `i8` cannot be safely transmuted into `u16` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, u16>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `u16` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `u16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:64:40
|
||||
@@ -36,15 +36,15 @@ error[E0277]: `i8` cannot be safely transmuted into `i32` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, i32>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `i32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:65:40
|
||||
@@ -52,15 +52,15 @@ error[E0277]: `i8` cannot be safely transmuted into `f32` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, f32>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `f32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:66:40
|
||||
@@ -68,15 +68,15 @@ error[E0277]: `i8` cannot be safely transmuted into `u32` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, u32>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:67:40
|
||||
@@ -84,15 +84,15 @@ error[E0277]: `i8` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, u64>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:68:40
|
||||
@@ -100,15 +100,15 @@ error[E0277]: `i8` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, i64>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:69:40
|
||||
@@ -116,15 +116,15 @@ error[E0277]: `i8` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, f64>();
|
||||
| ^^^ `i8` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:70:39
|
||||
@@ -132,15 +132,15 @@ error[E0277]: `i8` cannot be safely transmuted into `u128` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, u128>();
|
||||
| ^^^^ `i8` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i8` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:71:39
|
||||
@@ -148,15 +148,15 @@ error[E0277]: `i8` cannot be safely transmuted into `i128` in the defining scope
|
||||
LL | assert::is_transmutable::< i8, i128>();
|
||||
| ^^^^ `i8` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `i16` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:73:40
|
||||
@@ -164,15 +164,15 @@ error[E0277]: `u8` cannot be safely transmuted into `i16` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, i16>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `i16` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `i16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `u16` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:74:40
|
||||
@@ -180,15 +180,15 @@ error[E0277]: `u8` cannot be safely transmuted into `u16` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, u16>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `u16` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `u16`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u16`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:75:40
|
||||
@@ -196,15 +196,15 @@ error[E0277]: `u8` cannot be safely transmuted into `i32` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, i32>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `i32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:76:40
|
||||
@@ -212,15 +212,15 @@ error[E0277]: `u8` cannot be safely transmuted into `f32` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, f32>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `f32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:77:40
|
||||
@@ -228,15 +228,15 @@ error[E0277]: `u8` cannot be safely transmuted into `u32` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, u32>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:78:40
|
||||
@@ -244,15 +244,15 @@ error[E0277]: `u8` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, u64>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:79:40
|
||||
@@ -260,15 +260,15 @@ error[E0277]: `u8` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, i64>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:80:40
|
||||
@@ -276,15 +276,15 @@ error[E0277]: `u8` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, f64>();
|
||||
| ^^^ `u8` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:81:39
|
||||
@@ -292,15 +292,15 @@ error[E0277]: `u8` cannot be safely transmuted into `u128` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, u128>();
|
||||
| ^^^^ `u8` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u8` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:82:39
|
||||
@@ -308,15 +308,15 @@ error[E0277]: `u8` cannot be safely transmuted into `i128` in the defining scope
|
||||
LL | assert::is_transmutable::< u8, i128>();
|
||||
| ^^^^ `u8` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u8, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:84:40
|
||||
@@ -324,15 +324,15 @@ error[E0277]: `i16` cannot be safely transmuted into `i32` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, i32>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `i32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:85:40
|
||||
@@ -340,15 +340,15 @@ error[E0277]: `i16` cannot be safely transmuted into `f32` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, f32>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `f32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:86:40
|
||||
@@ -356,15 +356,15 @@ error[E0277]: `i16` cannot be safely transmuted into `u32` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, u32>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:87:40
|
||||
@@ -372,15 +372,15 @@ error[E0277]: `i16` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, u64>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:88:40
|
||||
@@ -388,15 +388,15 @@ error[E0277]: `i16` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, i64>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:89:40
|
||||
@@ -404,15 +404,15 @@ error[E0277]: `i16` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< i16, f64>();
|
||||
| ^^^ `i16` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:90:39
|
||||
@@ -420,15 +420,15 @@ error[E0277]: `i16` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< i16, u128>();
|
||||
| ^^^^ `i16` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i16` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:91:39
|
||||
@@ -436,15 +436,15 @@ error[E0277]: `i16` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< i16, i128>();
|
||||
| ^^^^ `i16` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:93:40
|
||||
@@ -452,15 +452,15 @@ error[E0277]: `u16` cannot be safely transmuted into `i32` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, i32>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `i32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `i32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:94:40
|
||||
@@ -468,15 +468,15 @@ error[E0277]: `u16` cannot be safely transmuted into `f32` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, f32>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `f32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `f32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:95:40
|
||||
@@ -484,15 +484,15 @@ error[E0277]: `u16` cannot be safely transmuted into `u32` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, u32>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `u32` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `u32`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u32`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:96:40
|
||||
@@ -500,15 +500,15 @@ error[E0277]: `u16` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, u64>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:97:40
|
||||
@@ -516,15 +516,15 @@ error[E0277]: `u16` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, i64>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:98:40
|
||||
@@ -532,15 +532,15 @@ error[E0277]: `u16` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< u16, f64>();
|
||||
| ^^^ `u16` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:99:39
|
||||
@@ -548,15 +548,15 @@ error[E0277]: `u16` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< u16, u128>();
|
||||
| ^^^^ `u16` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u16` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:100:39
|
||||
@@ -564,15 +564,15 @@ error[E0277]: `u16` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< u16, i128>();
|
||||
| ^^^^ `u16` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u16, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:102:40
|
||||
@@ -580,15 +580,15 @@ error[E0277]: `i32` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< i32, u64>();
|
||||
| ^^^ `i32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:103:40
|
||||
@@ -596,15 +596,15 @@ error[E0277]: `i32` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< i32, i64>();
|
||||
| ^^^ `i32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:104:40
|
||||
@@ -612,15 +612,15 @@ error[E0277]: `i32` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< i32, f64>();
|
||||
| ^^^ `i32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:105:39
|
||||
@@ -628,15 +628,15 @@ error[E0277]: `i32` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< i32, u128>();
|
||||
| ^^^^ `i32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:106:39
|
||||
@@ -644,15 +644,15 @@ error[E0277]: `i32` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< i32, i128>();
|
||||
| ^^^^ `i32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:108:40
|
||||
@@ -660,15 +660,15 @@ error[E0277]: `f32` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< f32, u64>();
|
||||
| ^^^ `f32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:109:40
|
||||
@@ -676,15 +676,15 @@ error[E0277]: `f32` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< f32, i64>();
|
||||
| ^^^ `f32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:110:40
|
||||
@@ -692,15 +692,15 @@ error[E0277]: `f32` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< f32, f64>();
|
||||
| ^^^ `f32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:111:39
|
||||
@@ -708,15 +708,15 @@ error[E0277]: `f32` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< f32, u128>();
|
||||
| ^^^^ `f32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:112:39
|
||||
@@ -724,15 +724,15 @@ error[E0277]: `f32` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< f32, i128>();
|
||||
| ^^^^ `f32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:114:40
|
||||
@@ -740,15 +740,15 @@ error[E0277]: `u32` cannot be safely transmuted into `u64` in the defining scope
|
||||
LL | assert::is_transmutable::< u32, u64>();
|
||||
| ^^^ `u32` cannot be safely transmuted into `u64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, false, false, false, false>` is not implemented for `u64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:115:40
|
||||
@@ -756,15 +756,15 @@ error[E0277]: `u32` cannot be safely transmuted into `i64` in the defining scope
|
||||
LL | assert::is_transmutable::< u32, i64>();
|
||||
| ^^^ `u32` cannot be safely transmuted into `i64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, false, false, false, false>` is not implemented for `i64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:116:40
|
||||
@@ -772,15 +772,15 @@ error[E0277]: `u32` cannot be safely transmuted into `f64` in the defining scope
|
||||
LL | assert::is_transmutable::< u32, f64>();
|
||||
| ^^^ `u32` cannot be safely transmuted into `f64` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, false, false, false, false>` is not implemented for `f64`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `f64`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:117:39
|
||||
@@ -788,15 +788,15 @@ error[E0277]: `u32` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< u32, u128>();
|
||||
| ^^^^ `u32` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:118:39
|
||||
@@ -804,15 +804,15 @@ error[E0277]: `u32` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< u32, i128>();
|
||||
| ^^^^ `u32` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u32, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:120:39
|
||||
@@ -820,15 +820,15 @@ error[E0277]: `u64` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< u64, u128>();
|
||||
| ^^^^ `u64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u64, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `u64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:121:39
|
||||
@@ -836,15 +836,15 @@ error[E0277]: `u64` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< u64, i128>();
|
||||
| ^^^^ `u64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u64, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:123:39
|
||||
@@ -852,15 +852,15 @@ error[E0277]: `i64` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< i64, u128>();
|
||||
| ^^^^ `i64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i64, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `i64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:124:39
|
||||
@@ -868,15 +868,15 @@ error[E0277]: `i64` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< i64, i128>();
|
||||
| ^^^^ `i64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<i64, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<i64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:126:39
|
||||
@@ -884,15 +884,15 @@ error[E0277]: `f64` cannot be safely transmuted into `u128` in the defining scop
|
||||
LL | assert::is_transmutable::< f64, u128>();
|
||||
| ^^^^ `f64` cannot be safely transmuted into `u128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f64, assert::Context, false, false, false, false>` is not implemented for `u128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `u128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `f64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
--> $DIR/numbers.rs:127:39
|
||||
@@ -900,15 +900,15 @@ error[E0277]: `f64` cannot be safely transmuted into `i128` in the defining scop
|
||||
LL | assert::is_transmutable::< f64, i128>();
|
||||
| ^^^^ `f64` cannot be safely transmuted into `i128` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<f64, assert::Context, false, false, false, false>` is not implemented for `i128`
|
||||
= help: the trait `BikeshedIntrinsicFrom<f64, assert::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `i128`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/numbers.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to 57 previous errors
|
||||
|
||||
|
||||
@@ -5,11 +5,16 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
error[E0277]: `()` cannot be safely transmuted into `u8` in the defining scope of `should_have_correct_size::Context`.
|
||||
--> $DIR/unit.rs:23:35
|
||||
--> $DIR/unit.rs:28:35
|
||||
|
|
||||
LL | assert::is_transmutable::<(), u8, Context>();
|
||||
| ^^ `()` cannot be safely transmuted into `u8` in the defining scope of `should_have_correct_size::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<(), should_have_correct_size::Context, true, true, true, true>` is not implemented for `u8`
|
||||
= help: the trait `BikeshedIntrinsicFrom<(), should_have_correct_size::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `u8`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/unit.rs:12:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -5,12 +5,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,25 @@
|
||||
error[E0277]: `&'static Unit` cannot be safely transmuted into `&'static Unit` in the defining scope of `assert::Context`.
|
||||
--> $DIR/references.rs:19:52
|
||||
--> $DIR/references.rs:26:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<&'static Unit, &'static Unit>();
|
||||
| ^^^^^^^^^^^^^ `&'static Unit` cannot be safely transmuted into `&'static Unit` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<&'static Unit, assert::Context, true, true, true, true>` is not implemented for `&'static Unit`
|
||||
= help: the trait `BikeshedIntrinsicFrom<&'static Unit, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `&'static Unit`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/references.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -6,12 +6,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,12 +6,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+168
-84
@@ -1,194 +1,278 @@
|
||||
error[E0277]: `should_reject_repr_rust::unit::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:21:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:28:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `should_reject_repr_rust::unit::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::unit::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::unit::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `should_reject_repr_rust::unit::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:22:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:29:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `should_reject_repr_rust::unit::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `should_reject_repr_rust::unit::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `should_reject_repr_rust::unit::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `should_reject_repr_rust::tuple::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:27:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:34:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `should_reject_repr_rust::tuple::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::tuple::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::tuple::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `should_reject_repr_rust::tuple::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:28:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:35:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `should_reject_repr_rust::tuple::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `should_reject_repr_rust::tuple::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `should_reject_repr_rust::tuple::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `should_reject_repr_rust::braces::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:33:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:40:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `should_reject_repr_rust::braces::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::braces::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::braces::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `should_reject_repr_rust::braces::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:34:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:41:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `should_reject_repr_rust::braces::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `should_reject_repr_rust::braces::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `should_reject_repr_rust::braces::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `aligned::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:39:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:46:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `aligned::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<aligned::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<aligned::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `aligned::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:40:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:47:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `aligned::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `aligned::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `aligned::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `packed::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:45:52
|
||||
--> $DIR/should_require_well_defined_layout.rs:52:52
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `packed::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<packed::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<packed::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `packed::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:46:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:53:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `packed::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `packed::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `packed::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `nested::repr_c` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:52:49
|
||||
--> $DIR/should_require_well_defined_layout.rs:59:49
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_c, ()>();
|
||||
| ^^ `nested::repr_c` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<nested::repr_c, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<nested::repr_c, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `nested::repr_c` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:53:47
|
||||
--> $DIR/should_require_well_defined_layout.rs:60:47
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_c>();
|
||||
| ^^^^^^ `u128` cannot be safely transmuted into `nested::repr_c` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `nested::repr_c`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `nested::repr_c`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to 12 previous errors
|
||||
|
||||
|
||||
@@ -6,12 +6,17 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -7,12 +7,12 @@
|
||||
#![allow(incomplete_features)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,12 +6,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,12 +6,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,19 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume {
|
||||
alignment: true,
|
||||
lifetimes: true,
|
||||
safety: true,
|
||||
validity: true,
|
||||
}
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,34 +1,48 @@
|
||||
error[E0277]: `should_reject_repr_rust::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:23:48
|
||||
--> $DIR/should_require_well_defined_layout.rs:30:48
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<repr_rust, ()>();
|
||||
| ^^ `should_reject_repr_rust::repr_rust` cannot be safely transmuted into `()` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::repr_rust, assert::Context, true, true, true, true>` is not implemented for `()`
|
||||
= help: the trait `BikeshedIntrinsicFrom<should_reject_repr_rust::repr_rust, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `()`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
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 `should_reject_repr_rust::repr_rust` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_require_well_defined_layout.rs:24:43
|
||||
--> $DIR/should_require_well_defined_layout.rs:31:43
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<u128, repr_rust>();
|
||||
| ^^^^^^^^^ `u128` cannot be safely transmuted into `should_reject_repr_rust::repr_rust` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, true, true, true, true>` is not implemented for `should_reject_repr_rust::repr_rust`
|
||||
= help: the trait `BikeshedIntrinsicFrom<u128, assert::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `should_reject_repr_rust::repr_rust`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_require_well_defined_layout.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume {
|
||||
LL | | alignment: true,
|
||||
LL | | lifetimes: true,
|
||||
... |
|
||||
LL | | }
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
|
||||
@@ -6,11 +6,16 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
Assume::ALIGNMENT
|
||||
.and(Assume::LIFETIMES)
|
||||
.and(Assume::SAFETY)
|
||||
.and(Assume::VALIDITY)
|
||||
}>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,24 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `should_pad_variants::Context`.
|
||||
--> $DIR/should_pad_variants.rs:39:36
|
||||
--> $DIR/should_pad_variants.rs:44:36
|
||||
|
|
||||
LL | assert::is_transmutable::<Src, Dst, Context>();
|
||||
| ^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `should_pad_variants::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, should_pad_variants::Context, true, true, true, true>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, should_pad_variants::Context, Assume { alignment: true, lifetimes: true, safety: true, validity: true }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_pad_variants.rs:13:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, true, true, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, {
|
||||
| ______________^
|
||||
LL | | Assume::ALIGNMENT
|
||||
LL | | .and(Assume::LIFETIMES)
|
||||
LL | | .and(Assume::SAFETY)
|
||||
LL | | .and(Assume::VALIDITY)
|
||||
LL | | }>
|
||||
| |__________^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
+2
-3
@@ -7,13 +7,12 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, true, true>
|
||||
// validity IS assumed --------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -5,12 +5,12 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,15 +4,15 @@ error[E0277]: `Superset` cannot be safely transmuted into `Subset` in the defini
|
||||
LL | assert::is_transmutable::<Superset, Subset>();
|
||||
| ^^^^^^ `Superset` cannot be safely transmuted into `Subset` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Superset, assert::Context, false, false, false, true>` is not implemented for `Subset`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Superset, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: false }>` is not implemented for `Subset`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_contraction.rs:13:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -5,13 +5,12 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_maybe_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, true, true>
|
||||
// validity IS assumed --------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,34 +1,34 @@
|
||||
error[E0277]: `A` cannot be safely transmuted into `B` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_reject_disjoint.rs:34:40
|
||||
--> $DIR/should_reject_disjoint.rs:33:40
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<A, B>();
|
||||
| ^ `A` cannot be safely transmuted into `B` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<A, assert::Context, false, false, true, true>` is not implemented for `B`
|
||||
= help: the trait `BikeshedIntrinsicFrom<A, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: true }>` is not implemented for `B`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_reject_disjoint.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error[E0277]: `B` cannot be safely transmuted into `A` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_reject_disjoint.rs:35:40
|
||||
--> $DIR/should_reject_disjoint.rs:34:40
|
||||
|
|
||||
LL | assert::is_maybe_transmutable::<B, A>();
|
||||
| ^ `B` cannot be safely transmuted into `A` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<B, assert::Context, false, false, true, true>` is not implemented for `A`
|
||||
= help: the trait `BikeshedIntrinsicFrom<B, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: true }>` is not implemented for `A`
|
||||
note: required by a bound in `is_maybe_transmutable`
|
||||
--> $DIR/should_reject_disjoint.rs:13:14
|
||||
|
|
||||
LL | pub fn is_maybe_transmutable<Src, Dst>()
|
||||
| --------------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, true, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY.and(Assume::VALIDITY) }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_maybe_transmutable`
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
|
||||
@@ -6,13 +6,13 @@
|
||||
#![allow(dead_code, incomplete_features, non_camel_case_types)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
pub struct Context;
|
||||
|
||||
pub fn is_transmutable<Src, Dst>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// validity is NOT assumed ----------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// validity is NOT assumed --------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,15 +4,15 @@ error[E0277]: `A` cannot be safely transmuted into `B` in the defining scope of
|
||||
LL | assert::is_transmutable::<A, B>();
|
||||
| ^ `A` cannot be safely transmuted into `B` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<A, assert::Context, false, false, false, true>` is not implemented for `B`
|
||||
= help: the trait `BikeshedIntrinsicFrom<A, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: false }>` is not implemented for `B`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_intersecting.rs:14:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error[E0277]: `B` cannot be safely transmuted into `A` in the defining scope of `assert::Context`.
|
||||
--> $DIR/should_reject_intersecting.rs:37:34
|
||||
@@ -20,15 +20,15 @@ error[E0277]: `B` cannot be safely transmuted into `A` in the defining scope of
|
||||
LL | assert::is_transmutable::<B, A>();
|
||||
| ^ `B` cannot be safely transmuted into `A` in the defining scope of `assert::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<B, assert::Context, false, false, false, true>` is not implemented for `A`
|
||||
= help: the trait `BikeshedIntrinsicFrom<B, assert::Context, Assume { alignment: false, lifetimes: false, safety: true, validity: false }>` is not implemented for `A`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_intersecting.rs:14:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
|
||||
+3
-3
@@ -7,12 +7,12 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// visibility IS assumed -------------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// safety IS assumed --------------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -7,12 +7,12 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// visibility IS assumed -------------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// safety IS assumed --------------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -13,12 +13,12 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// visibility IS assumed -------------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// safety IS assumed --------------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -8,12 +8,12 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// visibility IS assumed -------------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// safety IS assumed --------------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+3
-3
@@ -8,12 +8,12 @@
|
||||
#![allow(dead_code)]
|
||||
|
||||
mod assert {
|
||||
use std::mem::BikeshedIntrinsicFrom;
|
||||
use std::mem::{Assume, BikeshedIntrinsicFrom};
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, true>
|
||||
// visibility IS assumed -------------------------------------^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, { Assume::SAFETY }>
|
||||
// safety IS assumed --------------------^^^^^^^^^^^^^^^^^^
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,8 +11,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,8 +11,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+1
-2
@@ -11,8 +11,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
error[E0446]: private type `src::Zst` in public interface
|
||||
--> $DIR/should_accept_if_src_has_unreachable_field.rs:23:9
|
||||
--> $DIR/should_accept_if_src_has_unreachable_field.rs:22:9
|
||||
|
|
||||
LL | #[repr(C)] pub(self) struct Zst; // <- unreachable type
|
||||
| -------------------- `src::Zst` declared as private
|
||||
|
||||
@@ -11,8 +11,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -1,11 +1,11 @@
|
||||
error[E0603]: struct `Src` is private
|
||||
--> $DIR/should_accept_if_src_has_unreachable_ty.rs:38:36
|
||||
--> $DIR/should_accept_if_src_has_unreachable_ty.rs:37:36
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^ private struct
|
||||
|
|
||||
note: the struct `Src` is defined here
|
||||
--> $DIR/should_accept_if_src_has_unreachable_ty.rs:23:16
|
||||
--> $DIR/should_accept_if_src_has_unreachable_ty.rs:22:16
|
||||
|
|
||||
LL | #[repr(C)] pub(self) struct Src {
|
||||
| ^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
@@ -10,8 +10,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+4
-4
@@ -1,18 +1,18 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
--> $DIR/should_reject_if_dst_has_private_field.rs:36:41
|
||||
--> $DIR/should_reject_if_dst_has_private_field.rs:35:41
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^^^^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, false, false, false, false>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_if_dst_has_private_field.rs:13:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -10,8 +10,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+4
-4
@@ -1,18 +1,18 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
--> $DIR/should_reject_if_dst_has_private_variant.rs:37:41
|
||||
--> $DIR/should_reject_if_dst_has_private_variant.rs:36:41
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^^^^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, false, false, false, false>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_if_dst_has_private_variant.rs:13:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
+1
-2
@@ -23,8 +23,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+1
-2
@@ -12,8 +12,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+4
-4
@@ -1,18 +1,18 @@
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_field.rs:38:41
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_field.rs:37:41
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^^^^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, false, false, false, false>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_field.rs:15:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
||||
@@ -12,8 +12,7 @@ mod assert {
|
||||
|
||||
pub fn is_transmutable<Src, Dst, Context>()
|
||||
where
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
// visibility is NOT assumed ---------------------------------^^^^^
|
||||
Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
{}
|
||||
}
|
||||
|
||||
|
||||
+6
-6
@@ -1,30 +1,30 @@
|
||||
error[E0603]: struct `Dst` is private
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:39:46
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:38:46
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^ private struct
|
||||
|
|
||||
note: the struct `Dst` is defined here
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:32:16
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:31:16
|
||||
|
|
||||
LL | #[repr(C)] pub(self) struct Dst {
|
||||
| ^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
error[E0277]: `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:39:41
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:38:41
|
||||
|
|
||||
LL | assert::is_transmutable::<src::Src, dst::Dst, Context>();
|
||||
| ^^^^^^^^ `Src` cannot be safely transmuted into `Dst` in the defining scope of `test::Context`.
|
||||
|
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, false, false, false, false>` is not implemented for `Dst`
|
||||
= help: the trait `BikeshedIntrinsicFrom<Src, test::Context, Assume { alignment: false, lifetimes: false, safety: false, validity: false }>` is not implemented for `Dst`
|
||||
note: required by a bound in `is_transmutable`
|
||||
--> $DIR/should_reject_if_dst_has_unreachable_ty.rs:15:14
|
||||
|
|
||||
LL | pub fn is_transmutable<Src, Dst, Context>()
|
||||
| --------------- required by a bound in this
|
||||
LL | where
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context, false, false, false, false>
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
LL | Dst: BikeshedIntrinsicFrom<Src, Context> // safety is NOT assumed
|
||||
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `is_transmutable`
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
|
||||
Reference in New Issue
Block a user