Skip to content

Commit 1f71a0f

Browse files
committed
Clean up some FIXMEs related to impls
1 parent 3a20dda commit 1f71a0f

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

src/comp/middle/trans.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5354,7 +5354,7 @@ fn collect_item(ccx: @crate_ctxt, abi: @mutable option::t<ast::native_abi>,
53545354
register_fn(ccx, i.span, new_pt, "obj_ctor", tps, ctor_id);
53555355
}
53565356
ast::item_impl(tps, _, _, methods) {
5357-
let name = ccx.names.next(i.ident);
5357+
let name = i.ident + int::str(i.id);
53585358
for m in methods {
53595359
register_fn(ccx, i.span, pt + [name, m.ident],
53605360
"impl_method", tps + m.tps, m.id);
@@ -5418,9 +5418,7 @@ fn trans_constant(ccx: @crate_ctxt, it: @ast::item, &&pt: [str],
54185418
ast::item_impl(tps, some(@{node: ast::ty_path(_, id), _}), _, ms) {
54195419
let i_did = ast_util::def_id_of_def(ccx.tcx.def_map.get(id));
54205420
let ty = ty::lookup_item_type(ccx.tcx, i_did).ty;
5421-
// FIXME[impl] use the same name as used in collect_items, for
5422-
// slightly more consistent symbol names?
5423-
let new_pt = pt + [ccx.names.next(it.ident)];
5421+
let new_pt = pt + [it.ident + int::str(it.id), "wrap"];
54245422
let extra_tps = vec::map(tps, {|p| param_bounds(ccx, p)});
54255423
let tbl = C_struct(vec::map(*ty::iface_methods(ccx.tcx, i_did), {|im|
54265424
alt vec::find(ms, {|m| m.ident == im.ident}) {

src/comp/middle/typeck.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2920,8 +2920,6 @@ mod dict {
29202920
bind_params(fcx, self_ty, n_tps)
29212921
} else { {vars: [], ty: self_ty} };
29222922
let im_bs = ty::lookup_item_type(tcx, im.did).bounds;
2923-
// FIXME[impl] don't do this in fcx (or make
2924-
// unify transactional by scrubbing bindings on fail)
29252923
alt unify::unify(fcx, ty, self_ty) {
29262924
ures_ok(_) {
29272925
if option::is_some(found) {

0 commit comments

Comments
 (0)