Struct rustc_typeck::middle::ty::TransmuteRestriction
[−]
[src]
pub struct TransmuteRestriction<'tcx> {
pub span: Span,
pub original_from: &'tcx TyS<'tcx>,
pub original_to: &'tcx TyS<'tcx>,
pub substituted_from: &'tcx TyS<'tcx>,
pub substituted_to: &'tcx TyS<'tcx>,
pub id: u32,
}A restriction that certain types must be the same size. The use of
transmute gives rise to these restrictions. These generally
cannot be checked until trans; therefore, each call to transmute
will push one or more such restriction into the
transmute_restrictions vector during intrinsicck. They are
then checked during trans by the fn check_intrinsics.
Fields
span | Unstable The span whence the restriction comes. |
original_from | Unstable The type being transmuted from. |
original_to | Unstable The type being transmuted to. |
substituted_from | Unstable The type being transmuted from, with all type parameters substituted for an arbitrary representative. Not to be shown to the end user. |
substituted_to | Unstable The type being transmuted to, with all type parameters substituted for an arbitrary representative. Not to be shown to the end user. |
id | Unstable NodeId of the transmute intrinsic. |