mirror of
https://github.com/allankoechke/rust.git
synced 2026-12-02 09:47:57 +00:00
bootstrap: add bootstrap step to run stdarch-gen checks in CI
This PR ports stdarch-gen checks into the bootstrap test runner as a step, so that we can run the stdarch-gen checks via x.py test.
Changes -:
-> Adds a new `StdarchGenCheck` bootstrap step.
-> Mirrors `f71ac102d3/.github/workflows/main.yml (L309-L333)` (check-stdarch-gen job)
-> `stdarch-gen-arm` uses a nightly only feature (`#![feature(pattern)]`) but bootstrap's cargo runs on the beta toolchain thus we set `RUSTC_BOOTSTRAP=1` on the child process so it builds.
-> The generators call out to `rustfmt` to format their output so `rustfmt` needs to be on `PATH`. So added bootstrap's rustfmt to `PATH` before each run. If rustfmt isn't available, the step fails early and tells the user to set `rustfmt = true` in `bootstrap.toml` .
r? @Kobzol