pub struct LambdaCapture {
pub lambda_var: String,
pub ref_captures: Vec<String>,
pub lambda_scope: usize,
pub has_escaped: bool,
pub line: usize,
}Expand description
Track lambda captures and their escape potential
Fields§
§lambda_var: StringThe lambda variable name
ref_captures: Vec<String>Variables captured by reference
lambda_scope: usizeScope level where lambda was declared
has_escaped: boolWhether lambda has escaped (assigned to longer-lived variable or returned)
line: usizeLine number for error reporting
Trait Implementations§
Source§impl Clone for LambdaCapture
impl Clone for LambdaCapture
Source§fn clone(&self) -> LambdaCapture
fn clone(&self) -> LambdaCapture
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 LambdaCapture
impl RefUnwindSafe for LambdaCapture
impl Send for LambdaCapture
impl Sync for LambdaCapture
impl Unpin for LambdaCapture
impl UnwindSafe for LambdaCapture
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