pub enum Repeat {
Endless {
block: Block,
},
Iterating {
collection: Expr,
item: Variable,
block: Block,
},
Until {
condition: Expr,
block: Block,
},
}Expand description
Runs a Block forever or until a condition is met
Variants§
Implementations§
Trait Implementations§
Source§impl From<&mut Repeat> for HirElement
impl From<&mut Repeat> for HirElement
Source§fn from(repeat: &mut Repeat) -> HirElement
fn from(repeat: &mut Repeat) -> HirElement
Converts to this type from the input type.
Source§impl From<Repeat> for HirElement
impl From<Repeat> for HirElement
Source§fn from(repeat: Repeat) -> HirElement
fn from(repeat: Repeat) -> HirElement
Converts to this type from the input type.
Source§impl HasBlock for Repeat
impl HasBlock for Repeat
fn block_mut(&mut self) -> &mut Block
fn step<T>(&mut self, element: T) -> &mut Selfwhere
T: Into<HirElement>,
fn branch(&mut self) -> &mut Branch
fn repeat(&mut self) -> &mut Repeat
fn repeat_until(&mut self, condition: Expr) -> &mut Repeat
fn repeat_iterating<U, T>(&mut self, collection: U, item: T) -> &mut Repeat
Source§impl HirLowering for Repeat
impl HirLowering for Repeat
fn lower<'hir, 'lir>(&'hir self, runtime: &mut HirLoweringRuntime<'lir>)where
'hir: 'lir,
Auto Trait Implementations§
impl Freeze for Repeat
impl !RefUnwindSafe for Repeat
impl !Send for Repeat
impl !Sync for Repeat
impl Unpin for Repeat
impl UnsafeUnpin for Repeat
impl !UnwindSafe for Repeat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more