Commit graph

149311 commits

Author SHA1 Message Date
Luuk Wester
28399f9a80 add test for every keyword, fix bug 2024-05-24 22:41:49 +02:00
Luuk Wester
e0d1092d63 cosmetic and performance fixes, and drop support for adding //! comments anywhere, except
for at the top of files.
2024-05-24 21:56:55 +02:00
Weihang Lo
d1f0bc7562
bootstrap: test target specific config overrides
Debug, PartialEq, and Eq are derived for testing purposes.
2024-05-24 15:53:39 -04:00
Weihang Lo
9185ddb019
bootstrap: support target specific config overrides 2024-05-24 15:48:34 -04:00
Boxy
f856ee357c Remove DefId from EarlyParamRegion (clippy/smir) 2024-05-24 18:06:57 +01:00
Jubilee Young
14fc3fdb2c miri: receive the blessings of validate.rs 2024-05-24 09:56:56 -07:00
Jubilee Young
584975d606 clippy: unnest check_consts 2024-05-24 09:56:56 -07:00
Matthias Krüger
a2a68f2d3d
Rollup merge of #125481 - iawia002:fix-dead-link, r=lqd
Fix the dead link in the bootstrap README

This link has been changed since https://github.com/rust-lang/rustc-dev-guide/pull/1939
2024-05-24 17:48:03 +02:00
Matthias Krüger
eb6297eb6f
Rollup merge of #125477 - nnethercote:missed-rustfmt, r=compiler-errors
Run rustfmt on files that need it.

Somehow these files aren't properly formatted. By default `x fmt` and `x tidy` only check files that have changed against master, so if an ill-formatted file somehow slips in it can stay that way as long as it doesn't get modified(?)

I found these when I ran `x fmt` explicitly on every `.rs` file in the repo, while working on
https://github.com/rust-lang/compiler-team/issues/750.
2024-05-24 17:48:03 +02:00
Weihang Lo
99c9b0775f
Update rustc-perf 2024-05-24 11:25:46 -04:00
Guillaume Gomez
daff84372d Migrate run-make/rustdoc-with-output-dir-option to rmake.rs 2024-05-24 11:19:30 +02:00
bors
008f6b3a3f Auto merge of #3626 - devnexen:pthread_name_illumos, r=oli-obk
solaris add support for threadname.

from std::unix:🧵:set_name, pthread_setname_np is a weak symbol (not always had been available). Other than that, similar to linux only having twice of its buffer limit.
2024-05-24 09:09:43 +00:00
bors
7fc41d1bdf Auto merge of #3625 - Strophox:miri-allocation-fix, r=RalfJung
Bugfix `MiriAllocBytes` to guarantee different addresses

Fix in `alloc_bytes.rs` following https://github.com/rust-lang/miri/pull/3526

Currently when an allocation of `size == 0` is requested we return a `std::ptr::without_provenance_mut(align)`, but this means returned `ptr`s may overlap, which breaks things.
2024-05-24 08:11:36 +00:00
Ralf Jung
b84620ff17
extend comments 2024-05-24 10:10:07 +02:00
Xinzhao Xu
e78671e61f Fix the dead link in the bootstrap README 2024-05-24 15:44:12 +08:00
bors
88d519f718 Auto merge of #3628 - RalfJung:tokio, r=RalfJung
add back some tokio features

Turns out I went a bit too fer when I removed features, so `socketpair` was no longer used.
2024-05-24 06:37:35 +00:00
Ralf Jung
561bd9a5ec add back some tokio features 2024-05-24 08:19:17 +02:00
Urgau
1eda580516 Bump bootstrap compiler to the latest beta compiler 2024-05-24 08:07:39 +02:00
Nicholas Nethercote
c1ac4a2f28 Run rustfmt on files that need it.
Somehow these files aren't properly formatted. By default `x fmt` and `x
tidy` only check files that have changed against master, so if an
ill-formatted file somehow slips in it can stay that way as long as it
doesn't get modified(?)

I found these when I ran `x fmt` explicitly on every `.rs` file in the
repo, while working on
https://github.com/rust-lang/compiler-team/issues/750.
2024-05-24 15:17:21 +10:00
The Miri Cronjob Bot
4763eaf066 fmt 2024-05-24 05:05:00 +00:00
The Miri Cronjob Bot
debf88ae1a Merge from rustc 2024-05-24 05:03:54 +00:00
The Miri Cronjob Bot
9ce95c30b2 Preparing for merge from rustc 2024-05-24 04:56:26 +00:00
Erik Desjardins
5888de8cbe tidy: validate LLVM component names in tests
LLVM component names are not immediately obvious (they usually omit any
suffixes on the target arch name), and if they're incorrect, the test
will silently never run.
2024-05-23 22:53:32 -04:00
maxwase
14dc51c1ac Review fixes: Assist scope, trait qualify 2024-05-24 02:17:44 +03:00
David Carlier
7f5e0aade8 solaris add suport for threadname.
from std::unix:🧵:set_name, pthread_setname_np is a weak symbol
(not always had been available). Other than that, similar to
linux only having twice of its buffer limit.
2024-05-23 23:14:28 +00:00
maxwase
9cf35f1262 Review fixes: Split into 2, check tuple fields 2024-05-24 01:10:18 +03:00
maxwase
9244dbff76 Add toggle_async_sugar assist code action 2024-05-24 01:08:21 +03:00
Guillaume Gomez
a8a71d093e
Rollup merge of #125452 - Urgau:check-cfg-libraries-cleanup, r=bjorn3
Cleanup check-cfg handling in core and std

Follow-up to https://github.com/rust-lang/rust/pull/125296 where we:
 - expect any feature cfg in std, due to `#[path]` imports
 - move some check-cfg args inside the `build.rs` as per Cargo recommendation
 - and replace the fake Cargo feature `"restricted-std"` by the custom cfg `restricted_std`

Fixes https://github.com/rust-lang/rust/pull/125296#issuecomment-2127009301
r? `@bjorn3` (maybe, feel free to re-roll)
2024-05-23 23:39:29 +02:00
Guillaume Gomez
0de052acd8
Rollup merge of #125445 - GuillaumeGomez:rustdoc-migrate-short-out-dir, r=jieyouxu
Migrate `run-make/rustdoc-with-short-out-dir-option` to `rmake.rs`

Part of https://github.com/rust-lang/rust/issues/121876.

r? `@jieyouxu`
2024-05-23 23:39:28 +02:00
roife
3c7a13d870 tests: update test for runnables 2024-05-24 03:53:38 +08:00
roife
c10bda5577 Update docs 2024-05-24 03:53:36 +08:00
roife
1a37cfb703 Use cwd from runnable.args for debugger 2024-05-24 03:51:05 +08:00
roife
7b54c8231e Revert "Debug use cargo workspace root as cwd. fixes #13022"
This reverts commit 4ca86edac9.
2024-05-24 03:51:05 +08:00
roife
d83b267bc1 Add cwd to CargoRunnable 2024-05-24 03:51:04 +08:00
bors
6259991f04 Auto merge of #17287 - Veykril:sysroot-encode-empty, r=Veykril
Allow sysroots to only consist of the source root dir

Fixes https://github.com/rust-lang/rust-analyzer/issues/17159

This PR encodes the `None` case of an optional sysroot into `Sysroot` itself. This simplifies a lot of things and allows us to have sysroots that consist of nothing, only standard library sources, everything but the standard library sources or everything. This makes things a lot more flexible. Additionally, this removes the workspace status bar info again, as it turns out that that can be too much information for the status bar to handle (this is better rendered somewhere else, like in the status view).
2024-05-23 18:13:47 +00:00
Lukas Wirth
f93256ca42 Allow sysroots to only consist of the source root dir 2024-05-23 20:12:31 +02:00
León Orell Valerian Liehr
72cc4de660
Rollup merge of #125401 - GuillaumeGomez:migrate-rustdoc-scrape-examples-macros, r=jieyouxu
Migrate `run-make/rustdoc-scrape-examples-macros` to `rmake.rs`

Part of https://github.com/rust-lang/rust/issues/121876.

r? `````@jieyouxu`````
2024-05-23 20:09:10 +02:00
León Orell Valerian Liehr
d392d6849c
Rollup merge of #125227 - Oneirical:seventh, r=jieyouxu
Migrate `run-make/issue-30063` to `rmake`

Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

(Sorry about the [inconvenience](https://github.com/rust-lang/rust/pull/125224#issuecomment-2118340932) of all these PRs, this is the last one batched for today. I will discuss how we can cut these down a bit.)

The last check was previously commented out in the Makefile, and I have readded it. If it fails the CI, this can be reconsidered.
2024-05-23 20:09:09 +02:00
León Orell Valerian Liehr
e282b1f753
Rollup merge of #125224 - Oneirical:sixth, r=jieyouxu
Migrate `run-make/issue-53964` to `rmake`

Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

This is extremely similar to #125146. Could it be interesting to merge the two in some way? This one seems to do the same thing as the #125146, but with an added check that a useless lint is not shown.
2024-05-23 20:09:08 +02:00
bors
9c8a58fdb8 Auto merge of #116123 - joboet:rewrite_native_tls, r=m-ou-se
Rewrite native thread-local storage

(part of #110897)

The current native thread-local storage implementation has become quite messy, uses indescriptive names and unnecessarily adds code to the macro expansion. This PR tries to fix that by using a new implementation that also allows more layout optimizations and potentially increases performance by eliminating unnecessary TLS accesses.

This does not change the recursive initialization behaviour I described in [this comment](https://github.com/rust-lang/rust/issues/110897#issuecomment-1525705682), so it should be a library-only change. Changing that behaviour should be quite easy now, however.

r? `@m-ou-se`
`@rustbot` label +T-libs
2024-05-23 14:53:41 +00:00
Urgau
28689850e5 Move some expected cfgs to std build.rs as per Cargo recommandation 2024-05-23 16:08:31 +02:00
Strophox
1b374dfd9b differentiate between layout and alloc_layout 2024-05-23 16:00:23 +02:00
Urgau
a59589b1cc Replace fake "restricted-std" Cargo feature by custom cfg 2024-05-23 15:54:02 +02:00
Strophox
56c363b43e fix alloc_bytes (always allocate at least 1B) 2024-05-23 14:59:51 +02:00
Matthias Krüger
cf92f4c52f
Rollup merge of #125438 - tbu-:pr_rm_to_string_lossy, r=jieyouxu
Remove unneeded string conversion
2024-05-23 14:09:26 +02:00
Matthias Krüger
eb1b9b0048
Rollup merge of #125421 - Oneirical:bundle-them-yet-again, r=jieyouxu
Rewrite `core-no-oom-handling`, `issue-24445` and `issue-38237` `run-make` tests to new `rmake.rs` format

Part of #121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

The test which is now called `non-pie-thread-local` has an unexplained "only-linux" flag. Could it be worth trying to remove it and changing the CI to test non-Linux platforms on it?
2024-05-23 14:09:25 +02:00
Matthias Krüger
eda4a35f36
Rollup merge of #124976 - petrochenkov:usedcrates, r=oli-obk
rustc: Use `tcx.used_crates(())` more

And explain when it should be used.

Addresses comments from https://github.com/rust-lang/rust/pull/121167.
2024-05-23 14:09:23 +02:00
joboet
60bf1ab466
delete UI tests that only check internal implementation details of thread-locals 2024-05-23 13:44:56 +02:00
Guillaume Gomez
de644626c3 Migrate run-make/rustdoc-with-short-out-dir-option to rmake.rs 2024-05-23 12:28:51 +02:00
bors
ecadf37df4 Auto merge of #17284 - Veykril:doc-links, r=Veykril
fix: Use correct toolchain channel when generating builtin type doc links
2024-05-23 08:55:08 +00:00