Enum moore_vhdl::hir::Range2
source · [−]Expand description
A range.
See IEEE 1076-2008 section 5.2.1.
range := range.attribute_name | simple_expression direction simple_expression
Variants
Immediate(Span, Spanned<Dir>, &'t dyn Expr2<'t>, &'t dyn Expr2<'t>)
An range given by two immediate values.
Implementations
sourceimpl<'t> Range2<'t>
impl<'t> Range2<'t>
sourcepub fn bound_type<C>(&self, ctx: C) -> Result<&'t dyn Type> where
C: ExprContext<'t> + Copy,
pub fn bound_type<C>(&self, ctx: C) -> Result<&'t dyn Type> where
C: ExprContext<'t> + Copy,
Determine the type of the range.
This determines the type of the range’s bounds and applies any necessary implicit casts to make them be of the same type.
sourcepub fn constant_value<C>(
&self,
ctx: C
) -> Result<(Dir, &'t dyn Const2<'t>, &'t dyn Const2<'t>)> where
C: ExprContext<'t> + Copy,
pub fn constant_value<C>(
&self,
ctx: C
) -> Result<(Dir, &'t dyn Const2<'t>, &'t dyn Const2<'t>)> where
C: ExprContext<'t> + Copy,
Determine the constant value of the range.
Trait Implementations
Auto Trait Implementations
impl<'t> !RefUnwindSafe for Range2<'t>
impl<'t> !Send for Range2<'t>
impl<'t> !Sync for Range2<'t>
impl<'t> Unpin for Range2<'t>
impl<'t> !UnwindSafe for Range2<'t>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more