Fix overcapturing, unsafe extern blocks, and new unsafe ops

This commit is contained in:
Michael Goulet 2025-02-20 18:28:42 +00:00
parent 7f6873f64c
commit e1819a889a
7 changed files with 24 additions and 16 deletions

View file

@ -171,13 +171,15 @@ fn configure_and_expand(
new_path.push(path);
}
}
env::set_var(
"PATH",
&env::join_paths(
new_path.iter().filter(|p| env::join_paths(iter::once(p)).is_ok()),
)
.unwrap(),
);
unsafe {
env::set_var(
"PATH",
&env::join_paths(
new_path.iter().filter(|p| env::join_paths(iter::once(p)).is_ok()),
)
.unwrap(),
);
}
}
// Create the config for macro expansion
@ -216,7 +218,9 @@ fn configure_and_expand(
}
if cfg!(windows) {
env::set_var("PATH", &old_path);
unsafe {
env::set_var("PATH", &old_path);
}
}
krate