mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
Misc small cleanups
This commit is contained in:
parent
6fe59bf877
commit
38b2e2980e
@ -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 {
|
||||
|
@ -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 {
|
||||
|
@ -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);
|
||||
|
Loading…
Reference in New Issue
Block a user