Skip to content

Commit

Permalink
incr.comp.: Fix some merge fallout.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelwoerister committed Sep 29, 2017
1 parent 4ed2afa commit 762b735
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/librustc/ty/maps/plumbing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ pub fn force_from_dep_node<'a, 'gcx, 'lcx>(tcx: TyCtxt<'a, 'gcx, 'lcx>,

profq_msg!(tcx,
ProfileQueriesMsg::QueryBegin(
span.clone(),
span.data(),
::ty::maps::QueryMsg::$query(profq_key!(tcx, $key))
)
);
Expand Down
7 changes: 7 additions & 0 deletions src/librustc_incremental/persist/load.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ pub fn dep_graph_tcx_init<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>) {
tcx.allocate_metadata_dep_nodes();
tcx.precompute_in_scope_traits_hashes();

if tcx.sess.incr_comp_session_dir_opt().is_none() {
// If we are only building with -Zquery-dep-graph but without an actual
// incr. comp. session directory, we exit here. Otherwise we'd fail
// when trying to load work products.
return
}

let work_products_path = work_products_path(tcx.sess);
if let Some(work_products_data) = load_data(tcx.sess, &work_products_path) {
// Decode the list of work_products
Expand Down

0 comments on commit 762b735

Please sign in to comment.