Skip to content

Commit 8f385fc

Browse files
committed
middle: trans: callee: remove dead code
1 parent a2290cc commit 8f385fc

File tree

1 file changed

+0
-42
lines changed

1 file changed

+0
-42
lines changed

src/librustc/middle/trans/callee.rs

Lines changed: 0 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -512,48 +512,6 @@ pub fn trans_lang_call<'a>(
512512
dest)
513513
}
514514

515-
pub fn trans_lang_call_with_type_params<'a>(
516-
bcx: &'a Block<'a>,
517-
did: ast::DefId,
518-
args: &[ValueRef],
519-
type_params: &[ty::t],
520-
dest: expr::Dest)
521-
-> &'a Block<'a> {
522-
let fty;
523-
if did.krate == ast::LOCAL_CRATE {
524-
fty = ty::node_id_to_type(bcx.tcx(), did.node);
525-
} else {
526-
fty = csearch::get_type(bcx.tcx(), did).ty;
527-
}
528-
529-
return callee::trans_call_inner(
530-
bcx,
531-
None,
532-
fty,
533-
|bcx, _| {
534-
let callee =
535-
trans_fn_ref_with_vtables_to_callee(bcx, did, 0,
536-
type_params,
537-
None);
538-
539-
let new_llval;
540-
match callee.data {
541-
Fn(llfn) => {
542-
let substituted = ty::subst_tps(callee.bcx.tcx(),
543-
type_params,
544-
None,
545-
fty);
546-
let llfnty = type_of::type_of(callee.bcx.ccx(),
547-
substituted);
548-
new_llval = PointerCast(callee.bcx, llfn, llfnty);
549-
}
550-
_ => fail!()
551-
}
552-
Callee { bcx: callee.bcx, data: Fn(new_llval) }
553-
},
554-
ArgVals(args), Some(dest)).bcx;
555-
}
556-
557515
pub fn trans_call_inner<'a>(
558516
bcx: &'a Block<'a>,
559517
call_info: Option<NodeInfo>,

0 commit comments

Comments
 (0)