X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Flibrustc%2Fquery%2Fmod.rs;h=b8621c8ad30e2b65e22c5be1d8f5ce7c8fbbffc8;hb=760a98fb5e1c964efbe5cb36710fff892b547c51;hp=81aa8d434d37fa04e918f53c9a1b2aa69e5933b7;hpb=3013c0b698d7e294333be280e7051f96f7da2f41;p=rust.git diff --git a/src/librustc/query/mod.rs b/src/librustc/query/mod.rs index 81aa8d434d3..b8621c8ad30 100644 --- a/src/librustc/query/mod.rs +++ b/src/librustc/query/mod.rs @@ -42,7 +42,7 @@ load_cached(tcx, id) { let generics: Option = tcx.queries.on_disk_cache .try_load_query_result(tcx, id); - generics.map(|x| tcx.alloc_generics(x)) + generics.map(|x| &*tcx.arena.alloc(x)) } } @@ -118,7 +118,7 @@ load_cached(tcx, id) { let mir: Option> = tcx.queries.on_disk_cache .try_load_query_result(tcx, id); - mir.map(|x| tcx.alloc_mir(x)) + mir.map(|x| &*tcx.arena.alloc(x)) } } } @@ -353,7 +353,7 @@ .queries.on_disk_cache .try_load_query_result(tcx, id); - typeck_tables.map(|tables| tcx.alloc_tables(tables)) + typeck_tables.map(|tables| &*tcx.arena.alloc(tables)) } } } @@ -624,6 +624,10 @@ fatal_cycle desc { "test whether a crate has #![no_builtins]" } } + query symbol_mangling_version(_: CrateNum) -> SymbolManglingVersion { + fatal_cycle + desc { "query a crate's symbol mangling version" } + } query extern_crate(_: DefId) -> Option<&'tcx ExternCrate> { eval_always