pub struct EnhancedFor<VarName, Iter, Body> {
pub var_name: VarName,
pub iter: Iter,
pub body: Body,
}Expand description
An enhanced for loop in the style for (VarName : Iter) { Body }.
All fields of this struct must be writable.
Fields§
§var_name: VarNameThe variable type and name. Must be writable. DeclareParam will suffice in most cases
iter: IterThe iterator expression
body: BodyThe body of the for loop
Trait Implementations§
Source§impl<VarName: Clone, Iter: Clone, Body: Clone> Clone for EnhancedFor<VarName, Iter, Body>
impl<VarName: Clone, Iter: Clone, Body: Clone> Clone for EnhancedFor<VarName, Iter, Body>
Source§fn clone(&self) -> EnhancedFor<VarName, Iter, Body>
fn clone(&self) -> EnhancedFor<VarName, Iter, Body>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<O, VarName, Iter, Body> Writable<O> for EnhancedFor<VarName, Iter, Body>
impl<O, VarName, Iter, Body> Writable<O> for EnhancedFor<VarName, Iter, Body>
Auto Trait Implementations§
impl<VarName, Iter, Body> Freeze for EnhancedFor<VarName, Iter, Body>
impl<VarName, Iter, Body> RefUnwindSafe for EnhancedFor<VarName, Iter, Body>
impl<VarName, Iter, Body> Send for EnhancedFor<VarName, Iter, Body>
impl<VarName, Iter, Body> Sync for EnhancedFor<VarName, Iter, Body>
impl<VarName, Iter, Body> Unpin for EnhancedFor<VarName, Iter, Body>
impl<VarName, Iter, Body> UnwindSafe for EnhancedFor<VarName, Iter, Body>
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