Struct rustc_mir::transform::check_consts::qualifs::HasMutInterior [−][src]
pub struct HasMutInterior;
Expand description
Constant containing interior mutability (UnsafeCell<T>).
This must be ruled out to make sure that evaluating the constant at compile-time
and at any point during the run-time would produce the same result. In particular,
promotion of temporaries must not change program behavior; if the promoted could be
written to, that would be a problem.
Trait Implementations
impl Qualif for HasMutInterior[src]
impl Qualif for HasMutInterior[src]const ANALYSIS_NAME: &'static str[src]
const ANALYSIS_NAME: &'static str[src]The name of the file used to debug the dataflow analysis that computes this qualif.
fn in_qualifs(qualifs: &ConstQualifs) -> bool[src]
fn in_qualifs(qualifs: &ConstQualifs) -> bool[src]Extracts the field of ConstQualifs that corresponds to this Qualif.
fn in_any_value_of_ty<'tcx>(cx: &ConstCx<'_, 'tcx>, ty: Ty<'tcx>) -> bool[src]
fn in_any_value_of_ty<'tcx>(cx: &ConstCx<'_, 'tcx>, ty: Ty<'tcx>) -> bool[src]Returns true if any value of the given type could possibly have this Qualif. Read more
fn in_adt_inherently<'tcx>(
cx: &ConstCx<'_, 'tcx>,
adt: &'tcx AdtDef,
_: SubstsRef<'tcx>
) -> bool[src]
fn in_adt_inherently<'tcx>(
cx: &ConstCx<'_, 'tcx>,
adt: &'tcx AdtDef,
_: SubstsRef<'tcx>
) -> bool[src]Returns true if this Qualif is inherent to the given struct or enum. Read more
const IS_CLEARED_ON_MOVE: bool[src]
const IS_CLEARED_ON_MOVE: bool[src]Whether this Qualif is cleared when a local is moved from.
Auto Trait Implementations
impl RefUnwindSafe for HasMutInterior
impl Send for HasMutInterior
impl Sync for HasMutInterior
impl Unpin for HasMutInterior
impl UnwindSafe for HasMutInterior
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<T> WithConstness for T[src]
impl<T> WithConstness for T[src]