Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Scope Flattening

Now that all ends of scope are explicit, we can remove any blocks that aren't the target of a break 'label.

#![allow(unused)]
fn main() {
{
    let x;
    x = String::new();
}

// becomes
let x;
x = String::new();
}