Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix: Ignore
CARGO_BUILD_TARGET
in lib tests too
This follows from the previous commit. It turns out that `std::env::set_var` is unsafe: the `set_var` in bin tests leaked through the threads and caused `lib` tests to fail. To mitigate this problem we simply remove the `CARGO_BUILD_TARGET` variable in lib tests as well. This also improves correctness. Meanwhile we put `std::env::set_var` and `remove_var` in unsafe blocks as it would be required by Rust 2024.
- Loading branch information