§4 Statements and Control Flow
// Variableslet x = 10;let mut y = 0;
// Conditionalsif x > 5 { y = 1;} else if x == 5 { y = 0;} else { y = -1;}
// For loopfor item in items { process(item);}
// Conditional loop (desugars to `loop` plus a conditional `break`)while queue.length > 0 { handle(queue.pop());}
// Loop with break valuelet result = loop { let val = compute(); if val > threshold { break val; }};
// Match — see stability note belowmatch status { "active" => activate(), "paused" => pause(), _ => print.err("Unknown: {{ status }}"),}
// Try / catch / finally (err is bare, no type annotation)try { let data = fs.read(path); process(data);} catch (err) { print.err("Read failed: {{ err }}"); throw err;} finally { cleanup();}Assignment operators: =, +=, -=, *=, /=
Current
matchscope: Literal patterns,_, guards, and enum-variant destructuring lower end-to-end. Compile-time exhaustiveness checking remains partial, so emitted matches retain thematch_exhaustive_failedruntime backstop for an uncovered value.