Skip to content

Commit e2b9cdd

Browse files
committed
Switch impls_seen from oldmap
1 parent f0beb8c commit e2b9cdd

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/librustc/middle/typeck/check/vtable.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ use core::result::{Result, Ok, Err};
2828
use core::result;
2929
use core::uint;
3030
use core::vec;
31-
use std::oldmap::HashMap;
31+
use core::hashmap::linear::LinearSet;
3232
use syntax::ast;
3333
use syntax::ast_util;
3434
use syntax::codemap::span;
@@ -234,7 +234,7 @@ pub fn lookup_vtable(vcx: &VtableContext,
234234
_ => {
235235
let mut found = ~[];
236236
237-
let mut impls_seen = HashMap();
237+
let mut impls_seen = LinearSet::new();
238238
239239
match vcx.ccx.coherence_info.extension_methods.find(&trait_id) {
240240
None => {
@@ -250,10 +250,10 @@ pub fn lookup_vtable(vcx: &VtableContext,
250250
// im is one specific impl of trait_ty.
251251
252252
// First, ensure we haven't processed this impl yet.
253-
if impls_seen.contains_key(&im.did) {
253+
if impls_seen.contains(&im.did) {
254254
loop;
255255
}
256-
impls_seen.insert(im.did, ());
256+
impls_seen.insert(im.did);
257257
258258
// ty::impl_traits gives us the list of all
259259
// traits that im implements. Again, usually

0 commit comments

Comments
 (0)