Misc small cleanups

This commit is contained in:
Niko Matsakis 2013-08-11 13:34:18 -04:00
parent 6fe59bf877
commit 38b2e2980e
3 changed files with 1 additions and 9 deletions

View File

@ -2406,12 +2406,7 @@ pub fn fill_fn_pair(bcx: @mut Block, pair: ValueRef, llfn: ValueRef,
}
pub fn item_path(ccx: &CrateContext, id: &ast::NodeId) -> path {
match ccx.tcx.items.get_copy(id) {
ast_map::node_item(i, p) =>
vec::append((*p).clone(), [path_name(i.ident)]),
// separate map for paths?
_ => fail!("item_path")
}
ty::item_path(ccx.tcx, ast_util::local_def(*id))
}
fn exported_name(ccx: @mut CrateContext, path: path, ty: ty::t, attrs: &[ast::Attribute]) -> ~str {

View File

@ -687,7 +687,6 @@ pub fn tuplify_box_ty(tcx: ty::ctxt, t: ty::t) -> ty::t {
t]);
}
// LLVM constant constructors.
pub fn C_null(t: Type) -> ValueRef {
unsafe {

View File

@ -839,8 +839,6 @@ pub fn trans_intrinsic(ccx: @mut CrateContext,
"visit_tydesc" => {
let td = get_param(decl, first_real_arg);
let visitor = get_param(decl, first_real_arg + 1u);
//let llvisitorptr = alloca(bcx, val_ty(visitor));
//Store(bcx, visitor, llvisitorptr);
let td = PointerCast(bcx, td, ccx.tydesc_type.ptr_to());
glue::call_tydesc_glue_full(bcx, visitor, td,
abi::tydesc_field_visit_glue, None);