Make untracked.cstore lockable so that resolution can still write to it when using TyCtxt
This commit is contained in:
parent
e8e227aec8
commit
ade3dceb38
9 changed files with 50 additions and 36 deletions
|
@ -597,7 +597,7 @@ fn output_filenames(tcx: TyCtxt<'_>, (): ()) -> Arc<OutputFilenames> {
|
|||
}
|
||||
}
|
||||
|
||||
write_out_deps(sess, tcx.cstore_untracked(), &outputs, &output_paths);
|
||||
write_out_deps(sess, &*tcx.cstore_untracked(), &outputs, &output_paths);
|
||||
|
||||
let only_dep_info = sess.opts.output_types.contains_key(&OutputType::DepInfo)
|
||||
&& sess.opts.output_types.len() == 1;
|
||||
|
|
|
@ -215,6 +215,9 @@ impl<'tcx> Queries<'tcx> {
|
|||
ast_lowering: untracked_resolver_for_lowering,
|
||||
} = resolver_outputs;
|
||||
|
||||
// Make sure we don't mutate the cstore from here on.
|
||||
std::mem::forget(untracked.cstore.read());
|
||||
|
||||
let gcx = passes::create_global_ctxt(
|
||||
self.compiler,
|
||||
lint_store,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue