mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-14 02:49:40 +00:00
librustc: Speed up moves a lot. r=nmatsakis
This commit is contained in:
parent
bc2d147847
commit
a165f88272
@ -1932,6 +1932,10 @@ pub fn type_contents(cx: ctxt, ty: t) -> TypeContents {
|
||||
Some(tc) => { return *tc; }
|
||||
None => {}
|
||||
}
|
||||
match cx.tc_cache.find(&ty_id) { // Must check both caches!
|
||||
Some(tc) => { return *tc; }
|
||||
None => {}
|
||||
}
|
||||
cache.insert(ty_id, TC_NONE);
|
||||
|
||||
debug!("computing contents of %s", ty_to_str(cx, ty));
|
||||
|
Loading…
Reference in New Issue
Block a user