1
Fork 0
Commit graph

279948 commits

Author SHA1 Message Date
cyrgani
fb500c34ea add two old crash tests 2025-01-25 23:40:35 +01:00
wowinter13
2117afdef8 [Clippy] Add vec_reserve & vecdeque_reserve diagnostic items 2025-01-25 23:18:18 +01:00
Matthias Krüger
08c4d6369b
Rollup merge of #136056 - fee1-dead-contrib:push-tswyxkywqrtt, r=jieyouxu
Fix typo in const stability error message
2025-01-25 23:15:26 +01:00
Matthias Krüger
65fb6286e0
Rollup merge of #136039 - nvanbenschoten:pin-typo, r=Amanieu
docs: fix typo in std::pin overview

Unimportant fix in `std::pin` documentation.
2025-01-25 23:15:25 +01:00
Matthias Krüger
dbe911a64d
Rollup merge of #136016 - Urgau:check-cfg-allow-test-improv, r=jieyouxu
Improve check-cfg expected names diagnostic

This PR improves the check-cfg `allow-same-level` test by ~~normalizing it's output and by~~ adding more context to the test.

It also filters the well known cfgs from the `expected names are` note, as to reduce the size of the diagnostic. Users can still find the full list on the [rustc book](https://doc.rust-lang.org/nightly/rustc/check-cfg.html#well-known-names-and-values), which is reinforced for Cargo users by adding a note in the Cargo check-cfg specific section.

Fixes https://github.com/rust-lang/rust/issues/135995
r? `@jieyouxu`
2025-01-25 23:15:25 +01:00
Matthias Krüger
f14993b454
Rollup merge of #136005 - BLANKatGITHUB:library, r=RalfJung
ports last few library files to new intrinsic style

This pr ports the last 2 library files to new intrinsic style this pr is part of issue #132735
2025-01-25 23:15:24 +01:00
Matthias Krüger
f42163621f
Rollup merge of #135934 - ferrocene:pa-1.81-relnotes, r=Mark-Simulacrum
Include missing item in the 1.81 release notes

It was pointed out to me that when I prepared the CVE-2024-43402 fix in the stable branch, I added the release notes in the stable PR (https://github.com/rust-lang/rust/pull/129960), but I forgot to do so in the beta or nightly PR. Because of that, the relnotes line only appeared in 1.81, and disappeared afterwards.
2025-01-25 23:15:24 +01:00
Matthias Krüger
20d0f0187d
Rollup merge of #134373 - joshtriplett:pipe-docs, r=joboet
Improve and expand documentation of pipes

- Reference UNIX, not just Linux
- Simplify some of the language
- Don't imply that pipes *only* work across multiple processes; instead,
  *suggest* that they're typically used across two or more separate
  processes.
- Specify that portable applications cannot use multiple readers or
  multiple writers for messages larger than a byte, due to potential
  interleaving.

Tracking issue for anonymous pipes:
https://github.com/rust-lang/rust/issues/127154
2025-01-25 23:15:23 +01:00
Matthias Krüger
f01d418139
Rollup merge of #134300 - RalfJung:remove-dead-attrs, r=chenyukang
remove long-deprecated no-op attributes no_start and crate_id

These have emitted a deprecation warning since forever (https://github.com/rust-lang/rust/pull/64471) and they already don't do anything. In fact they [apparently](https://github.com/rust-lang/rust/pull/64471#issuecomment-531517332) have done nothing since pre-1.0, so... do we even need a crater run? Doesn't seem worth it.
2025-01-25 23:15:22 +01:00
Chayim Refael Friedman
9ae0e7bb25 Don't complete doc(hidden) enum variants and use trees
Also refactor the check a bit.
2025-01-26 00:13:11 +02:00
bors
6fb03584cf Auto merge of #135707 - jyn514:linker-messages-2, r=bjorn3
Shorten linker output even more when `--verbose` is not present

- Don't show environment variables. Seeing PATH is almost never useful, and it can be extremely long.
- For .rlibs in the sysroot, replace crate hashes with a `"-*"` string. This will expand to the full crate name when pasted into the shell.
- Move `.rlib` to outside the glob.
- Abbreviate the sysroot path to `<sysroot>` wherever it appears in the arguments.

This also adds an example of the linker output as a run-make test. Currently it only runs on x86_64-unknown-linux-gnu, because each platform has its own linker arguments. So that it's stable across machines, pass BUILD_ROOT as an argument through compiletest through to run-make tests.

r? `@bjorn3`

try-job: aarch64-apple
2025-01-25 22:05:02 +00:00
Eric Huss
40e051f1bf Update boring lines to sync with rustdoc 2025-01-25 13:49:32 -08:00
jyn
c1b4ab0e73 Shorten linker output even more when --verbose is not present
- Don't show environment variables. Seeing PATH is almost never useful, and it can be extremely long.
- For .rlibs in the sysroot, replace crate hashes with a `"-*"` string. This will expand to the full crate name when pasted into the shell.
- Move `.rlib` to outside the glob.
- Abbreviate the sysroot path to `<sysroot>` wherever it appears in the arguments.

This also adds an example of the linker output as a run-make test. Currently it only runs on x86_64-unknown-linux-gnu, because each platform has its own linker arguments. So that it's stable across machines, pass BUILD_ROOT as an argument through compiletest through to run-make tests.

- Only use linker-flavor=gnu-cc if we're actually going to compare the output. It doesn't exist on MacOS.
2025-01-25 16:04:52 -05:00
Michael Goulet
6e1690a504 Pass spans to perform_locally_in_new_solver 2025-01-25 20:53:34 +00:00
Luca Versari
6bdc8778db Add a suggestion to cast target_feature fn items to fn pointers.
See
https://github.com/rust-lang/rust/pull/134090#issuecomment-2612197095
for the motivation behind this suggestion.
2025-01-25 21:36:40 +01:00
Josh Triplett
687607c31e Improve and expand documentation of pipes
- Simplify some of the language
- Minor grammar fixes
- Don't imply that pipes *only* work across multiple processes; instead,
  *suggest* that they're typically used across two or more separate
  processes.
- Specify that portable applications cannot use multiple readers or
  multiple writers for messages larger than a byte, due to potential
  interleaving.
- Remove no-longer-referenced footnote URLs.
2025-01-25 22:15:54 +02:00
Lukas Wirth
2d94c69c6b
Merge pull request #19020 from ShoyuVanilla/issues-19007
fix: Prevent infinite recursion of bounds formatting
2025-01-25 19:03:54 +00:00
Shoyu Vanilla
9691d2201c fix: Prevent infinite recursion of bounds formatting 2025-01-26 03:37:00 +09:00
wowinter13
beeb6f7432 slice-as-bytes: pedantic -> perf 2025-01-25 18:43:07 +01:00
wowinter13
4e94d22291 nit: change placeholders 2025-01-25 18:43:07 +01:00
wowinter13
5855e0a2f1 Small refactoring: irrefutable let pattern 2025-01-25 18:43:07 +01:00
wowinter13
4fef1b46be Fix tests 2025-01-25 18:43:07 +01:00
wowinter13
26a7b322a3 Rename slice_as_bytes -> sliced_string_as_bytes 2025-01-25 18:43:07 +01:00
wowinter13
9e83183f7e uibless for tests 2025-01-25 18:42:45 +01:00
wowinter13
43066fea88 Fix related test 2025-01-25 18:42:45 +01:00
wowinter13
7124d822b4 Fix function signature 2025-01-25 18:42:45 +01:00
wowinter13
307d85409b Address linter & changelog issues 2025-01-25 18:42:45 +01:00
wowinter13
2ad20daa2a Rollback CHANGELOG.md change 2025-01-25 18:42:45 +01:00
wowinter13
c214f5144e Update CHANGELOG.md 2025-01-25 18:42:45 +01:00
wowinter13
d8752dbf40 New lint 2025-01-25 18:42:43 +01:00
Martin Liska
1392e074b7 CI: use key-restore for cache GH action
It seems one can't overwrite a cache entry:
```
Failed to save: Unable to reserve cache with key linkcheck--0.8.1, another job may be creating this cache. More details: Cache already exists. Scope: refs/heads/master, Key: linkcheck--0.8.1, Version: 33f8fd511bed9c91c40778bc5c27cb58425caa894ab50f9c5705d83cb78660e0
Warning: Cache save failed.
```

A proper solution is to use `restore-keys`:
https://github.com/actions/cache/blob/main/tips-and-workarounds.md#update-a-cache
2025-01-25 18:22:00 +01:00
bors
f7cc13af82 Auto merge of #119286 - jyn514:linker-output, r=bjorn3
show linker output even if the linker succeeds

Show stderr and stderr by default, controlled by a new `linker_messages` lint.

fixes https://github.com/rust-lang/rust/issues/83436. fixes https://github.com/rust-lang/rust/issues/38206. cc https://rust-lang.zulipchat.com/#narrow/stream/233931-t-compiler.2Fmajor-changes/topic/uplift.20some.20-Zverbose.20calls.20and.20rename.20to.E2.80.A6.20compiler-team.23706/near/408986134

<!-- try-job: dist-x86_64-msvc -->
try-job: aarch64-apple

r? `@bjorn3`
2025-01-25 17:16:33 +00:00
Deadbeef
626d3ba514 Fix typo in const stability error message 2025-01-25 21:43:22 +08:00
Lukas Wirth
c1db5da2fe
Merge pull request #19030 from Veykril/push-wuzvopyooznm
fix: Fix markdown horizontal ruler sometimes being treated as a heading
2025-01-25 13:22:39 +00:00
Lukas Wirth
a5cd6c0756 fix: Fix markdown horizontal ruler sometimes being treated as a heading 2025-01-25 14:07:54 +01:00
Lukas Wirth
80615d963d
Merge pull request #18909 from Veykril/push-rrpprwwzttkt
Use `strict_provenance`
2025-01-25 13:06:26 +00:00
Lukas Wirth
105ea3bc1d Use strict_provenance 2025-01-25 13:47:07 +01:00
Lukas Wirth
a91b571b5f
Merge pull request #19029 from Veykril/push-wklzwzqvkrou
internal: Skip redundant path search in `resolve_completion_edits`
2025-01-25 12:17:22 +00:00
Lukas Wirth
5d94c97ddb Skip redundant path search in resolve_completion_edits 2025-01-25 13:03:01 +01:00
bors
203e6c127c Auto merge of #133154 - estebank:issue-133137, r=wesleywiser
Reword resolve errors caused by likely missing crate in dep tree

Reword label and add `help`:

```
error[E0432]: unresolved import `some_novel_crate`
 --> f704.rs:1:5
  |
1 | use some_novel_crate::Type;
  |     ^^^^^^^^^^^^^^^^ use of unresolved module or unlinked crate `some_novel_crate`
  |
  = help: if you wanted to use a crate named `some_novel_crate`, use `cargo add some_novel_crate` to add it to your `Cargo.toml`
```

Fix #133137.
2025-01-25 11:41:21 +00:00
Urgau
74223e4667 Refer to the well known names from Cargo check-cfg specifics doc 2025-01-25 12:37:29 +01:00
Lukas Wirth
58401ab0c8
Merge pull request #19028 from Veykril/push-vuytpkvqzwzs
fix: Fix flyimport not filtering via stability of import path
2025-01-25 11:34:36 +00:00
Urgau
c5ea75a5df Filter well known names from check-cfg diagnostics 2025-01-25 12:27:33 +01:00
Lukas Wirth
0db8d05b52 Fix flyimport not filtering via stability of import path 2025-01-25 12:18:54 +01:00
lapla-cogito
db977689fd
trigger obfuscated_if_else for .then(..).unwrap_or(..) 2025-01-25 19:57:22 +09:00
llogiq
4825666bd3
add new lint non_std_lazy_statics (#13770)
fixes #12895

detects usage of `once_cell::sync::Lazy` and `lazy_static!`,
recommending usage of `std::sync::LazyLock` instead

Many thanks to @J-ZhengLi for putting in most of the work in #12968

----

changelog: new lint [`non_std_lazy_statics`]
2025-01-25 10:31:14 +00:00
Lukas Wirth
f45b8ad7f8
Merge pull request #19026 from Veykril/push-wrxrutptywzx
Only collect implicit visibile use symbols if they have renames
2025-01-25 10:27:26 +00:00
Lukas Wirth
592eceedf5 Only collect implicit visibile use symbols if they have renames
Otherwise this will pollute the index too much with unnecessary symbols
2025-01-25 11:12:06 +01:00
Lukas Wirth
37fc7ee6bb
Merge pull request #18973 from ThouCheese/feat/nice-niches
Make niches into nices
2025-01-25 09:17:05 +00:00
bors
f94018810c Auto merge of #136041 - matthiaskrgr:rollup-5r1k45x, r=matthiaskrgr
Rollup of 9 pull requests

Successful merges:

 - #135971 (Properly report error when object type param default references self)
 - #135977 (Fix `FormattingOptions` instantiation with `Default`)
 - #135985 (Rename test to `unresolvable-upvar-issue-87987.rs` and add some notes)
 - #135991 (Fix set_name in thread mod for NuttX)
 - #136009 (bootstrap: Handle bootstrap lockfile race condition better)
 - #136018 (Use short ty string for move errors)
 - #136027 (Skip suggestions in `derive`d code)
 - #136029 (Bootstrap: Don't move ownership of job object)
 - #136034 (fix(bootstrap): deserialize null as `f64::NAN`)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-01-25 08:56:41 +00:00