From 600747a1b42c0cd666d19b102e91ded048dac567 Mon Sep 17 00:00:00 2001 From: Lukas Wirth Date: Tue, 2 Apr 2024 15:04:40 +0200 Subject: [PATCH] Fix `patch_cfg_if` not applying with stitched sysroot --- crates/project-model/src/workspace.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/project-model/src/workspace.rs b/crates/project-model/src/workspace.rs index d752b2f32ee..b59c0d59e47 100644 --- a/crates/project-model/src/workspace.rs +++ b/crates/project-model/src/workspace.rs @@ -775,7 +775,7 @@ pub fn to_crate_graph( ), }; - if matches!(sysroot.as_ref().map(|it| it.mode()), Ok(SysrootMode::Workspace(_))) + if matches!(sysroot.as_ref().map(|it| it.mode()), Ok(SysrootMode::Stitched(_))) && crate_graph.patch_cfg_if() { tracing::debug!("Patched std to depend on cfg-if")