Skip to main content

find_state_change

Function find_state_change 

Source
fn find_state_change<'hir>(
    gcx: Gcx<'hir>,
    hir: &'hir Hir<'hir>,
    current_contract: Option<ContractId>,
    expr: &'hir Expr<'hir>,
) -> Option<Span>
Expand description

Recursively searches expr for the first sub-expression that modifies state. Returns its span so the diagnostic points at exactly where the mutation occurs.