Skip to content

Commit 762b735

Browse files
incr.comp.: Fix some merge fallout.
1 parent 4ed2afa commit 762b735

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

src/librustc/ty/maps/plumbing.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -651,7 +651,7 @@ pub fn force_from_dep_node<'a, 'gcx, 'lcx>(tcx: TyCtxt<'a, 'gcx, 'lcx>,
651651

652652
profq_msg!(tcx,
653653
ProfileQueriesMsg::QueryBegin(
654-
span.clone(),
654+
span.data(),
655655
::ty::maps::QueryMsg::$query(profq_key!(tcx, $key))
656656
)
657657
);

src/librustc_incremental/persist/load.rs

+7
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ pub fn dep_graph_tcx_init<'a, 'tcx>(tcx: TyCtxt<'a, 'tcx, 'tcx>) {
3333
tcx.allocate_metadata_dep_nodes();
3434
tcx.precompute_in_scope_traits_hashes();
3535

36+
if tcx.sess.incr_comp_session_dir_opt().is_none() {
37+
// If we are only building with -Zquery-dep-graph but without an actual
38+
// incr. comp. session directory, we exit here. Otherwise we'd fail
39+
// when trying to load work products.
40+
return
41+
}
42+
3643
let work_products_path = work_products_path(tcx.sess);
3744
if let Some(work_products_data) = load_data(tcx.sess, &work_products_path) {
3845
// Decode the list of work_products

0 commit comments

Comments
 (0)