pub fn in_breakable_scope<F, R>(&mut self,
                                    loop_block: Option<BasicBlock>,
                                    break_block: BasicBlock,
                                    break_destination: Lvalue<'tcx>,
                                    f: F) -> R
        where F: FnOnce(&mut Builder<'a, 'gcx, 'tcx>) -> R
    {
        let extent = self.topmost_scope();
        let scope = BreakableScope {
            extent,
            continue_block: loop_block,
            break_block,
            break_destination,
        };
        self.breakable_scopes.push(scope);
        let res = f(self);
        let breakable_scope = self.breakable_scopes.pop().unwrap();
        assert!(breakable_scope.extent == extent);
        res
    }
// Adding and removing scopes
// ==========================
/// Start a breakable scope, which tracks where `continue` and `break`
/// should branch to. See module comment for more details.
///
/// Returns the might_break attribute of the BreakableScope used.
Adding and removing scopes
Start a breakable scope, which tracks where `continue` and `break`
should branch to. See module comment for more details.

Returns the might_break attribute of the BreakableScope used.
Adding and removing scopes Start a breakable scope which tracks where ` continue ` and ` break ` should branch to . See module comment for more details . Returns the might_break attribute of the BreakableScope used .
pub fn in_breakable_scope<F, R>(&mut self,
                                    loop_block: Option<BasicBlock>,
                                    break_block: BasicBlock,
                                    break_destination: Lvalue<'tcx>,
                                    f: F) -> R
        where F: FnOnce(&mut Builder<'a, 'gcx, 'tcx>) -> R
    {
        let extent = self.topmost_scope();
        let scope = BreakableScope {
            extent,
            continue_block: loop_block,
            break_block,
            break_destination,
        };
        self.breakable_scopes.push(scope);
        let res = f(self);
        let breakable_scope = self.breakable_scopes.pop().unwrap();
        assert!(breakable_scope.extent == extent);
        res
    }
pub fn in_breakable_scope < F , R > ( & mut self , loop_block : Option < BasicBlock > , break_block : BasicBlock , break_destination : Lvalue < ' tcx > , f : F ) -> R where F : FnOnce ( & mut Builder < ' a , ' gcx , ' tcx > ) -> R { let extent = self . topmost_scope ( ) ; let scope = BreakableScope { extent , continue_block : loop_block , break_block , break_destination , } ; self . breakable_scopes . push ( scope ) ; let res = f ( self ) ; let breakable_scope = self . breakable_scopes . pop ( ) . unwrap ( ) ; assert ! ( breakable_scope extent extent ) ; res }
Adding and removing scopes
Start a breakable scope, which tracks where `continue` and `break`
should branch to.
Adding and removing scopes Start a breakable scope which tracks where ` continue ` and ` break ` should branch to .
&mut self
loop_block
Option<BasicBlock>
break_block
BasicBlock
break_destination
Lvalue<'tcx>
f
F
&mut self
loop_block
Option<BasicBlock>
break_block
BasicBlock
break_destination
Lvalue<'tcx>
f
F