leo/compiler/tests/mutability/function_input_mut.leo

6 lines
120 B
Plaintext

// Adding the `mut` keyword makes a function variable mutable.
function main(mut a: u32) -> u32 {
a = 0;
return a
}