tests: copy generated-rust-toolchain.toml to test directories#1430
Merged
tests: copy generated-rust-toolchain.toml to test directories#1430
generated-rust-toolchain.toml to test directories#1430Conversation
In `test_translator.py`, we `c2rust-transpile` `*.c` files individually, so `--emit-build-files` doesn't work as intended, since it'd be used per-file and emit in the wrong directory (in `src/`, not parallel to the `Cargo.toml`). We could change things to transpile all `*.c` files at once, but that'd be a more involved change. So we just link `generated-rust-toolchain.toml` to `rust-toolchain.toml`. This should finally fully fix the CI errors due `c2rust-bitfields-derive` resolving `syn v2.0.107`, which can't build on our pinned nightly.
ahomescu
reviewed
Oct 23, 2025
fw-immunant
reviewed
Oct 23, 2025
fw-immunant
reviewed
Oct 23, 2025
fw-immunant
approved these changes
Oct 23, 2025
Contributor
fw-immunant
left a comment
There was a problem hiding this comment.
A couple comments inline. Only the TRANSPILE_CRATE_DIR one is blocking.
It would be nice to clearly document in the README what Rust version transpiled code targets, whether we state it concretely or point to the relevant rust-toolchain.toml.
Base automatically changed from
kkysen/update-generated-rust-version
to
master
October 23, 2025 19:19
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In
test_translator.py, wec2rust-transpile*.cfiles individually, so--emit-build-filesdoesn't work as intended, since it'd be used per-file and emit in the wrong directory (insrc/, not parallel to theCargo.toml). We could change things to transpile all*.cfiles at once, but that'd be a more involved change. So we just linkgenerated-rust-toolchain.tomltorust-toolchain.toml.This should finally fully fix the CI errors due
c2rust-bitfields-deriveresolvingsyn v2.0.107, which can't build on our pinned nightly.