bootstrap: set correct path for the build-manifest binary
This changes the path of the binary inside the tarball to be:
```
build-manifest-{release}-{target}/build-manifest/bin/build-manifest
```
...instead of:
```
build-manifest-{release}-{target}/build-manifest/bin/build-manifest/build-manifest
```
r? @Mark-Simulacrum
Replace absolute paths with relative ones
Modern compilers allow reaching external crates
like std or core via relative paths in modules
outside of lib.rs and main.rs.
Replace trivial bool matches with the `matches!` macro
This derives `PartialEq` on one enum (and two structs it contains) to enable the `==` operator for it. If there's some downside to this, I could respin with the `matches!` macro instead.
Include `llvm-dis`, `llc` and `opt` in `llvm-tools-preview` component
Fixes#55890
It's useful to have `llc` and `opt` available when debugging an LLVM
miscompilation,.
Mention rustdoc in `x.py setup`
This lets new contributors know which option they should pick; previously it wasn't clear 'compiler' also included rustdoc.
Unresolved questions: should this say 'compiler and tools' instead? I don't know of any tools that are modified in-tree other than rustdoc, though.
r? @Mark-Simulacrum
Give an error when running `x.py test --stage 0 src/test/ui`
The error can be overridden with `COMPILETEST_FORCE_STAGE0=1`. In practice I don't know why anyone would do this.
r? @Mark-Simulacrum
Closes https://github.com/rust-lang/rust/issues/77711
Remove unsafety from sys/unsupported and add deny(unsafe_op_in_unsafe_fn).
Replacing `UnsafeCell`s by a `Cell`s simplifies things and makes the mutex and rwlock implementations safe. Other than that, only unsafety in strlen() contained unsafe code.
@rustbot modify labels: +F-unsafe-block-in-unsafe-fn +C-cleanup
Dist build manifest
This PR makes two changes that should remove a significant chunk of the time spent in our release process: cloning the `rust-lang/rust` monorepo, all its submodules, and building `bootstrap` to then invoke `build-manifest`:
* `build-manifest` doesn't rely on a clone of the monorepo being present anymore. The only remaining bit of information it fetched from it (the Rust version) is instead bundled in the binary.
* A new "component" is added, `build-manifest`. That component includes a prebuilt version of the tool, and it's *not* included in the Rustup manifest. This will allow `promote-release` to directly invoke the tool without interacting with our build system.
* The Linux x86_64 CI is changed to also build the component mentioned above. It's the only CI builder tasked to do so, and to cleanly support this a new `--include-default-paths` flag was added to `./x.py`.
* The `BUILD_MANIFEST_NUM_THREADS` environment variable is added to configure the number of threads at runtime.
This PR is best reviewed commit-by-commit.
r? `@Mark-Simulacrum`
ci: Fix riscv64gc linux test QEMU fault, plus doc link fix
Newer versions of the `qemu` package (used for riscv64gc-unknown-linux-gnu testing) don't work with the version of the RISC-V bootloader we were using. a4a0342cf5 bumps to a revision which should fix the problem.
e0b033e965 fixes a documentation failure I encountered while running the tests.
Stabilize slice_partition_at_index
This stabilizes slice_partition_at_index, including renaming `partition_at_index*` -> `select_nth_unstable*`.
Closes#55300
r? `@Amanieu`
rustdoc: skip #[allow(missing docs)] for docs in coverage report
During the document coverage reporting with:
```bash
rustdoc something.rs -Z unstable-options --show-coverage
```
the coverage report counts code that is marked with `#[allow(missing_docs)]` for the calculation, which outputs lower numbers in the coverage report even though these parts should be ignored for the calculation.
Right now I'm not sure how this can be tested (CI)? (I verified it by hand and ran the unit tests)
r? `@jyn514`
**Reference:** Fixes#76121
Use tracing spans in rustc_trait_selection
Spans are very helpful when debugging this code. It's also hot enough to make a good benchmark.
r? `@oli-obk`
Rollup of 10 pull requests
Successful merges:
- #77550 (add shims for WithOptConstParam query calls)
- #77699 (Add word wrap for short descriptions)
- #77724 (Implement `AsRawFd` for `StdinLock` etc. on WASI.)
- #77746 (Fix `x.py setup` sets `changelog-seen`)
- #77784 (Fix intra-docs link in core::ffi::VaList)
- #77811 (rustdoc: Make some functions private that don't need to be public)
- #77818 (Mono collector: replace pair of ints with Range)
- #77831 (Use std methods on char instead of open coding them)
- #77852 (update url in bootstrap README (gcc-rs -> cc-rs))
- #77863 (Remove `mark-i-m` from rustc-dev-guide maintainers)
Failed merges:
r? `@ghost`
Mono collector: replace pair of ints with Range
I found the initial PR (#33171) that introduced this piece of code but I didn't find any information about why a tuple was preferred over a `Range<usize>`.
I'm hoping there are no technical reasons to not do this.
Implement `AsRawFd` for `StdinLock` etc. on WASI.
WASI implements `AsRawFd` for `Stdin`, `Stdout`, and `Stderr`, so
implement it for `StdinLock`, `StdoutLock`, and `StderrLock` as well.
r? @alexcrichton