Remove duplicate definition of def_to_str from middle::ty
This commit is contained in:
parent
e29ef1bec2
commit
4304f8d4f6
@ -178,7 +178,6 @@ export type_is_str;
|
||||
export type_owns_heap_mem;
|
||||
export type_autoderef;
|
||||
export type_param;
|
||||
export def_to_str;
|
||||
export unify;
|
||||
export variant_info;
|
||||
export walk_ty;
|
||||
@ -1300,9 +1299,6 @@ fn type_autoderef(&ctxt cx, &ty::t t) -> ty::t {
|
||||
ret t1;
|
||||
}
|
||||
|
||||
fn def_to_str(&ast::def_id did) -> str { ret #fmt("%d:%d", did._0, did._1); }
|
||||
|
||||
|
||||
// Type hashing. This function is private to this module (and slow); external
|
||||
// users should use `hash_ty()` instead.
|
||||
fn hash_type_structure(&sty st) -> uint {
|
||||
|
@ -151,7 +151,7 @@ fn ty_to_str(&ctxt cx, &t typ) -> str {
|
||||
}
|
||||
|
||||
fn ty_to_short_str(&ctxt cx, t typ) -> str {
|
||||
auto f = def_to_str;
|
||||
auto f = metadata::encoder::def_to_str;
|
||||
auto ecx = @rec(ds=f, tcx=cx, abbrevs=metadata::tyencode::ac_no_abbrevs);
|
||||
auto s = metadata::tyencode::ty_str(ecx, typ);
|
||||
if (str::byte_len(s) >= 32u) { s = str::substr(s, 0u, 32u); }
|
||||
|
Loading…
x
Reference in New Issue
Block a user