Previously all lints were assumed to be `#[warn]`, and we had a hand-coded list of `#[allow]` exceptions. Now the severity is autogenerated from rustdoc output.
Also support lints that change status between editions, and the `warnings` lint group.
rustc_target: ppc64 target string fixes for LLVM 20
LLVM continues to clean these up, and we continue to make this consistent. This is similar to 9caced7bad, e985396145, and
a10e744faf.
```@rustbot``` label: +llvm-main
Add the `power8-crypto` target feature
Add the `power8-crypto` target feature. This will enable adding some new PPC intrinsics in stdarch (specifically AES, SHA and CLMUL intrinsics). The implied target feature is from [here](https://github.com/llvm/llvm-project/blob/main/llvm/lib/Target/PowerPC/PPC.td)
```@rustbot``` label A-target-feature O-PowerPC
bootstrap: Forward cargo JSON output to stdout, not stderr
This fixes the RA errors I've been seeing on proc-macros after the re-landing of #134040.
r? clubby789
Don't use `AsyncFnOnce::CallOnceFuture` bounds for signature deduction
We shouldn't be using `AsyncFnOnce::CallOnceFuture` projection bounds to deduce anything about the return type of an async closure, **only** `AsyncFnOnce::Output`. This was accidental b/c all we were looking at was the def id of the trait, rather than the projection. This PR fixes that.
This doesn't affect stable code, since `CallOnceFuture` bounds cannot be written on stable.
Fixes#134015
Make `Copy` unsafe to implement for ADTs with `unsafe` fields
As a rule, the application of `unsafe` to a declaration requires that use-sites of that declaration also entail `unsafe`. For example, a field declared `unsafe` may only be read in the lexical context of an `unsafe` block.
For nearly all safe traits, the safety obligations of fields are explicitly discharged when they are mentioned in method definitions. For example, idiomatically implementing `Clone` (a safe trait) for a type with unsafe fields will require `unsafe` to clone those fields.
Prior to this commit, `Copy` violated this rule. The trait is marked safe, and although it has no explicit methods, its implementation permits reads of `Self`.
This commit resolves this by making `Copy` conditionally safe to implement. It remains safe to implement for ADTs without unsafe fields, but unsafe to implement for ADTs with unsafe fields.
Tracking: #132922
r? ```@compiler-errors```
[AIX] Remove option "-n" from AIX "ln" command
The option `-n` for the AIX `ln` command has a different purpose than it does on Linux. On Linux, the `-n` option is used to treat the destination path as normal file if it is a symbolic link to a directory, which is the default behavior of the AIX `ln` command.
[AIX] Replace sa_sigaction with sa_union.__su_sigaction for AIX
On AIX, the `sa_sigaction` member of `struct sigaction` is accessed as the union member `sa_union.__su_sigaction`.
[AIX] Pass -bnoipath when adding rust upstream dynamic crates
Unlike ELF linkers, AIX doesn't feature `DT_SONAME` to override
the dependency name when outputing a shared library, which is something
we rely on for dylib crates.
See for reference:
bc145cec45/compiler/rustc_codegen_ssa/src/back/linker.rs (L464))
Thus, `ld` on AIX will use the full path to shared libraries as the dependency if passed it
by default unless `noipath` is passed, so pass it here so we don't end up with full path dependencies
for dylib crates.
jsondocck: Parse, don't validate commands.
Centralizes knowledge of jsondocck syntax into the parser, so the checker doesn't need to know what the indexes are.
[Vaguely related zulip discussion](https://rust-lang.zulipchat.com/#narrow/channel/266220-t-rustdoc/topic/jsondocck.20rewrite)
I'm very happy this is negative LoC, despite adding a big, documented enum!
r? ``@fmease``
LLVM continues to clean these up, and we continue to make this
consistent. This is similar to 9caced7bad,
e985396145, and
a10e744faf.
`@rustbot` label: +llvm-main
Rollup of 10 pull requests
Successful merges:
- #131558 (Lint on combining `#[no_mangle]` and `#[export_name]`)
- #133184 (wasi/fs: Improve stopping condition for <ReadDir as Iterator>::next)
- #133456 (Add licenses + Run `cargo update`)
- #133472 (Run TLS destructors for wasm32-wasip1-threads)
- #133853 (use vendor sources by default on dist tarballs)
- #133946 (coverage: Prefer to visit nodes whose predecessors have been visited)
- #134010 (fix ICE on type error in promoted)
- #134029 (coverage: Use a query to find counters/expressions that must be zero)
- #134071 (Configure renovatebot)
- #134102 (Miscellaneous fixes for nix-dev-shell)
r? `@ghost`
`@rustbot` modify labels: rollup
Miscellaneous fixes for nix-dev-shell
this makes it so files in `src/nix-dev-shell` are *not* ignored, as they
should not be. note that `flake.lock` is still ignored globally.
r? `@Noratrieb`
See individual commits for more info.
cc #131176 (it added gitignore entries I'm changing).
Configure renovatebot
This PR adds a basic Renovatebot configuration. We would mostly like to use the bot for updating lockfiles. First, I want to try out if the built-in lockFileMaintenance will work for that. I'm a bit skeptical, because it is not very configurable, but it's worth a try. I set the schedule for Tuesday, so that we can test what happens tomorrow.
I also enabled the dependency dashboard, as I think it could be useful for us, to see a global state of our dependencies.
r? ```@MarcoIeni```
coverage: Use a query to find counters/expressions that must be zero
As of #133446, this query (`coverage_ids_info`) determines which counter/expression IDs are unused. So with only a little extra work, we can take the code that was using that information to determine which coverage counters/expressions must be zero, and move that inside the query as well.
There should be no change in compiler output.