charon_lib::ast::gast_utils

Function make_locals_generator

source
pub fn make_locals_generator(
    locals: &mut Vector<VarId, Var>,
) -> impl FnMut(Ty) -> VarId + '_
Expand description

Makes a lambda that generates a new variable id, pushes a new variable in the body locals with the given type and returns its id.