pub enum LoopPattern {
ForRange {
var: String,
start: String,
end: String,
inclusive: bool,
},
While {
condition: String,
},
Loop,
}Expand description
Represents recognized loop patterns from Rust DSL.
Variants§
ForRange
for i in start..end - exclusive range
While
while condition { ... }
Loop
loop { ... } - infinite loop with break
Implementations§
Source§impl LoopPattern
impl LoopPattern
Sourcepub fn to_wgsl_header(&self) -> String
pub fn to_wgsl_header(&self) -> String
Generate the WGSL loop header.
Trait Implementations§
Source§impl Clone for LoopPattern
impl Clone for LoopPattern
Source§fn clone(&self) -> LoopPattern
fn clone(&self) -> LoopPattern
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 moreAuto Trait Implementations§
impl Freeze for LoopPattern
impl RefUnwindSafe for LoopPattern
impl Send for LoopPattern
impl Sync for LoopPattern
impl Unpin for LoopPattern
impl UnwindSafe for LoopPattern
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