Skip to content

Commit 6d95765

Browse files
committed
Cleanup: remove useless parameter
1 parent fc3297f commit 6d95765

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

src/librustc/middle/trans/_match.rs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1294,18 +1294,14 @@ fn store_non_ref_bindings(bcx: @mut Block,
12941294

12951295
fn insert_lllocals(bcx: @mut Block,
12961296
bindings_map: &BindingsMap,
1297-
binding_mode: IrrefutablePatternBindingMode,
12981297
add_cleans: bool) -> @mut Block {
12991298
/*!
13001299
* For each binding in `data.bindings_map`, adds an appropriate entry into
13011300
* the `fcx.lllocals` map. If add_cleans is true, then adds cleanups for
13021301
* the bindings.
13031302
*/
13041303

1305-
let llmap = match binding_mode {
1306-
BindLocal => bcx.fcx.lllocals,
1307-
BindArgument => bcx.fcx.llargs
1308-
};
1304+
let llmap = bcx.fcx.lllocals;
13091305

13101306
for (&ident, &binding_info) in bindings_map.iter() {
13111307
let llval = match binding_info.trmode {
@@ -1358,7 +1354,7 @@ fn compile_guard(bcx: @mut Block,
13581354
bcx = store_non_ref_bindings(bcx,
13591355
data.bindings_map,
13601356
Some(&mut temp_cleanups));
1361-
bcx = insert_lllocals(bcx, data.bindings_map, BindLocal, false);
1357+
bcx = insert_lllocals(bcx, data.bindings_map, false);
13621358

13631359
let val = unpack_result!(bcx, {
13641360
do with_scope_result(bcx, guard_expr.info(),
@@ -1875,7 +1871,7 @@ fn trans_match_inner(scope_cx: @mut Block,
18751871
}
18761872

18771873
// insert bindings into the lllocals map and add cleanups
1878-
bcx = insert_lllocals(bcx, arm_data.bindings_map, BindLocal, true);
1874+
bcx = insert_lllocals(bcx, arm_data.bindings_map, true);
18791875

18801876
bcx = controlflow::trans_block(bcx, &arm_data.arm.body, dest);
18811877
bcx = trans_block_cleanups(bcx, block_cleanups(arm_data.bodycx));

0 commit comments

Comments
 (0)