fn insert_lllocals<'blk, 'tcx>(mut bcx: Block<'blk, 'tcx>,
                               bindings_map: &BindingsMap<'tcx>,
                               cs: Option<cleanup::ScopeId>)
                               -> Block<'blk, 'tcx> {
    for (&ident, &binding_info) in bindings_map {
        let llval = match binding_info.trmode {
            // By value mut binding for a copy type: load from the ptr
            // into the matched value and copy to our alloca
            TrByCopy(llbinding) => {
                let llval = Load(bcx, binding_info.llmatch);
                let datum = Datum::new(llval, binding_info.ty, Lvalue);
                call_lifetime_start(bcx, llbinding);
                bcx = datum.store_to(bcx, llbinding);
                if let Some(cs) = cs {
                    bcx.fcx.schedule_lifetime_end(cs, llbinding);
                }

                llbinding
            },

            // By value move bindings: load from the ptr into the matched value
            TrByMove => Load(bcx, binding_info.llmatch),

            // By ref binding: use the ptr into the matched value
            TrByRef => binding_info.llmatch
        };

        let datum = Datum::new(llval, binding_info.ty, Lvalue);
        if let Some(cs) = cs {
            bcx.fcx.schedule_drop_and_zero_mem(cs, llval, binding_info.ty);
            bcx.fcx.schedule_lifetime_end(cs, binding_info.llmatch);
        }

        debug!("binding {} to {}", binding_info.id, bcx.val_to_string(llval));
        bcx.fcx.lllocals.borrow_mut().insert(binding_info.id, datum);
        debuginfo::create_match_binding_metadata(bcx, ident, binding_info);
    }
    bcx
}
/// For each binding in `data.bindings_map`, adds an appropriate entry into the `fcx.lllocals` map
For each binding in `data.bindings_map`, adds an appropriate entry into the `fcx.lllocals` map
For each binding in ` data . bindings_map ` adds an appropriate entry into the ` fcx . lllocals ` map
fn insert_lllocals<'blk, 'tcx>(mut bcx: Block<'blk, 'tcx>,
                               bindings_map: &BindingsMap<'tcx>,
                               cs: Option<cleanup::ScopeId>)
                               -> Block<'blk, 'tcx> {
    for (&ident, &binding_info) in bindings_map {
        let llval = match binding_info.trmode {
            // By value mut binding for a copy type: load from the ptr
            // into the matched value and copy to our alloca
            TrByCopy(llbinding) => {
                let llval = Load(bcx, binding_info.llmatch);
                let datum = Datum::new(llval, binding_info.ty, Lvalue);
                call_lifetime_start(bcx, llbinding);
                bcx = datum.store_to(bcx, llbinding);
                if let Some(cs) = cs {
                    bcx.fcx.schedule_lifetime_end(cs, llbinding);
                }
                llbinding
            },
            // By value move bindings: load from the ptr into the matched value
            TrByMove => Load(bcx, binding_info.llmatch),
            // By ref binding: use the ptr into the matched value
            TrByRef => binding_info.llmatch
        };
        let datum = Datum::new(llval, binding_info.ty, Lvalue);
        if let Some(cs) = cs {
            bcx.fcx.schedule_drop_and_zero_mem(cs, llval, binding_info.ty);
            bcx.fcx.schedule_lifetime_end(cs, binding_info.llmatch);
        }
        debug!("binding {} to {}", binding_info.id, bcx.val_to_string(llval));
        bcx.fcx.lllocals.borrow_mut().insert(binding_info.id, datum);
        debuginfo::create_match_binding_metadata(bcx, ident, binding_info);
    }
    bcx
}
fn insert_lllocals < ' blk , ' tcx > ( mut bcx : Block < ' blk , ' tcx > , bindings_map : & BindingsMap < ' tcx > , cs : Option < cleanup :: ScopeId > ) -> Block < ' blk , ' tcx > { for ( & ident , & binding_info ) in bindings_map { let llval = match binding_info . trmode { // By value mut binding for a copy type: load from the ptr // into the matched value and copy to our alloca TrByCopy ( llbinding ) => { let llval = Load ( bcx , binding_info . llmatch ) ; let datum = Datum :: new ( llval , binding_info . ty , Lvalue ) ; call_lifetime_start ( bcx , llbinding ) ; bcx = datum . store_to ( bcx , llbinding ) ; if let Some ( cs ) = cs { bcx . fcx . schedule_lifetime_end ( cs , llbinding ) ; } llbinding } , // By value move bindings: load from the ptr into the matched value TrByMove => Load ( bcx , binding_info . llmatch ) , // By ref binding: use the ptr into the matched value TrByRef => binding_info . llmatch } ; let datum = Datum :: new ( llval , binding_info . ty , Lvalue ) ; if let Some ( cs ) = cs { bcx . fcx . schedule_drop_and_zero_mem ( cs , llval , binding_info . ty ) ; bcx . fcx . schedule_lifetime_end ( cs , binding_info . llmatch ) ; } debug ! ( " " binding_info id bcx val_to_string ( llval ) ) ; bcx . fcx . lllocals . borrow_mut ( ) . insert ( binding_info . id , datum ) ; debuginfo :: create_match_binding_metadata ( bcx , ident , binding_info ) ; } bcx }
For each binding in `data.bindings_map`, adds an appropriate entry into the `fcx.lllocals` map
For each binding in ` data . bindings_map ` adds an appropriate entry into the ` fcx . lllocals ` map
bcx
Block<'blk, 'tcx>
bindings_map
&BindingsMap<'tcx>
cs
Option<cleanup::ScopeId>
bcx
Block<'blk, 'tcx>
bindings_map
&BindingsMap<'tcx>
cs
Option<cleanup::ScopeId>