Port `tests/run-make-fulldeps/hotplug_codegen_backend` to ui-fulldeps
This is the last remaining run-make-fulldeps test, which means I actually had to leave behind a dummy README file to prevent compiletest from complaining about a missing directory.
(Removing the run-make-fulldeps suite entirely is non-trivial, so I intend to do so in a separate PR after this one.)
---
I wasn't sure about adding a new kind of aux build just for this one test, so I also tried to just port this test from Makefile to [rmake](https://github.com/rust-lang/rust/issues/121876) instead.
But I found that I couldn't get rmake to fully work for a run-make-fulldeps test, which convinced me that getting rid of run-make-fulldeps is worthwhile.
r? `@jieyouxu`
Add debugging utils and comments to Fuchsia scripts
This should help when debugging a failure in the Fuchsia build in CI.
I plan to follow up with a PR to the testing section of the dev guide with more details, along with more improvements happening in the Fuchsia repo itself.
try-job: x86_64-gnu-integration
mark binding undetermined if target name exist and not obtained
- Fixes#124490
- Fixes#125013
Following up on #124840, I think handling only `target_bindings` is sufficient.
r? `@petrochenkov`
Make html rendered by rustdoc allow searching non-English identifier / alias
Fix alias search result showing `undefined` description.
Inspired by https://github.com/rust-lang/mdBook/issues/2393 .
Not sure if it's worth it adding full-text search functionality to rustdoc rendered html.
std::unix::fs::get_mode implementation for illumos/solaris.
they both support the F_GETFL fctnl flag/O_ACCMODE mask to get the file descriptor access modes.
Rollup of 11 pull requests
Successful merges:
- #124012 (Stabilize `binary_heap_as_slice`)
- #124214 (Parse unsafe attributes)
- #125572 (Detect pub structs never constructed and unused associated constants)
- #125781 (prefer `compile::stream_cargo` for building tools)
- #126030 (Update `./x fmt` command in library/std/src/sys/pal/windows/c/README.md)
- #126047 (Simplify the rayon calls in the installer)
- #126052 (More `rustc_parse` cleanups)
- #126077 (Revert "Use the HIR instead of mir_keys for determining whether something will have a MIR body.")
- #126089 (Stabilize Option::take_if)
- #126112 (Clean up source root in run-make tests)
- #126119 (Improve docs for using custom paths with `--emit`)
r? `@ghost`
`@rustbot` modify labels: rollup
Improve docs for using custom paths with `--emit`
Recently I found myself concluding that this feature didn't exist (https://github.com/rust-lang/rust/pull/126111#discussion_r1630707215), despite having read the documentation, because it was hidden away in the middle of a paragraph full of other information.
Giving this documentation more space of its own should make it easier to find.
Clean up source root in run-make tests
The name `S` isn't exactly the most descriptive, and we also shouldn't need to pass it when building (actually I think that most of the env. vars that we pass to `cargo` here are probably not really needed).
Related issue: https://github.com/rust-lang/rust/issues/126071
r? ```@jieyouxu```
Revert "Use the HIR instead of mir_keys for determining whether something will have a MIR body."
This reverts commit e5cba17b84.
turns out SMIR still needs it (https://github.com/model-checking/kani/issues/3218). I'll create a full plan and MCP for what I intended this to be a part of. Maybe my plan is nonsense anyway.
prefer `compile::stream_cargo` for building tools
Previously, we were running bare commands for `ToolBuild` step and were unable to utilize some of the flags which are already handled by `compile::stream_cargo`.
This change makes `ToolBuild` to use `compile::stream_cargo`, allowing us to benefit from the flags supported by the bootstrap cargo.
Resolves#125666
Detect pub structs never constructed and unused associated constants
<!--
If this PR is related to an unstable feature or an otherwise tracked effort,
please link to the relevant tracking issue here. If you don't know of a related
tracking issue or there are none, feel free to ignore this.
This PR will get automatically assigned to a reviewer. In case you would like
a specific user to review your work, you can assign it to them by using
r? <reviewer name>
-->
Lints never constructed public structs.
If we don't provide public methods to construct public structs with private fields, and don't construct them in the local crate. They would be never constructed. So that we can detect such public structs.
---
Update:
Also lints unused associated constants in traits.
Parse unsafe attributes
Initial parse implementation for #123757
This is the initial work to parse unsafe attributes, which is represented as an extra `unsafety` field in `MetaItem` and `AttrItem`. There's two areas in the code where it appears that parsing is done manually and not using the parser stuff, and I'm not sure how I'm supposed to thread the change there.
rustdoc: Refactor doctest collection and running code
This code previously had a quite confusing structure, mixing the collection,
processing, and running of doctests with multiple layers of indirection. There
are also many cases where tons of parameters are passed to functions with little
typing information (e.g., booleans or strings are often used).
As a result, the source of bugs is obfuscated (e.g. #81070) and large changes
(e.g. #123974) become unnecessarily complicated. This PR is a first step to try
to simplify the code and make it easier to follow and less bug-prone.
r? `@GuillaumeGomez`
This code turns the raw code given by the user into something actually
runnable, e.g. by adding a `main` function if it doesn't already exist.
I also made a couple other items private that didn't need to be
crate-public.
This was used to get the line number of the first line from the current
docstring, which was then used together with an offset within the
docstring. It's simpler to just pass the offset to the visitor and have
it do the math because it's clearer and this calculation only needs to
be done in one place (the Rust doctest visitor).