about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2025-01-10ci: Move dist-aarch64-linux to an aarch64 runnerKajetan Puchalski-43/+241
Move the dist-aarch64-linux CI job to an aarch64 runner instead of cross-compiling it from an x86 one. This will make it possible to perform optimisations such as LTO, PGO and BOLT later on.
2025-01-10Auto merge of #135273 - dianne:argument-patterns-are-not-boring, r=lqdbors-20/+9
Remove special-casing for argument patterns in MIR typeck (attempt to fix perf regression of #133858) See [my comment](https://github.com/rust-lang/rust/pull/133858#issuecomment-2579029618) on #133858 for more information. This is just a guess as to what went wrong, and I haven't been able to get the profiler running locally, so I'll need a perf run to make sure this actually helps. There's one test's stderr that suffers a bit, but this was just papering over the issue anyway. Making region errors point to the correct constraints in the presence of invariance/contravariance is a broader problem; the current way it's handled is mostly based on guesswork, luck, and hoping it works out. Properly handling that (somehow) would improve the test's stderr without the hack that this PR reverts.
2025-01-10Auto merge of #135319 - matthiaskrgr:rollup-un5lol6, r=matthiaskrgrbors-124/+738
Rollup of 8 pull requests Successful merges: - #133088 (`-Zrandomize-layout` harder. `Foo<T> != Foo<U>`) - #134619 (Improve prose around `as_slice` example of IterMut) - #134855 (Add `default_field_values` entry to unstable book) - #134908 (Fix `ptr::from_ref` documentation example comment) - #135275 (Add Pin::as_deref_mut to 1.84 relnotes) - #135294 (Make `bare-fn-no-impl-fn-ptr-99875` test less dependent on path width) - #135304 (Add tests cases from review of #132289) - #135308 (Make sure to walk into nested const blocks in `RegionResolutionVisitor`) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-10Rollup merge of #135308 - compiler-errors:scope-visit, r=oli-obkMatthias Krüger-16/+36
Make sure to walk into nested const blocks in `RegionResolutionVisitor` Fixes https://github.com/rust-lang/rust/issues/135306 I tried auditing the rest of the visitors that called `.visit_body`, and it seems like this is the only one that was missing it. I wonder if we should modify intravisit (specifcially, that `NestedBodyFilter` stuff) to make this less likely to happen, tho... r? oli-obk
2025-01-10Rollup merge of #135304 - steffahn:tests_from_132289, r=compiler-errorsMatthias Krüger-0/+178
Add tests cases from review of #132289 Adding my comments as test-cases as suggested by ``@jackh726`` in https://github.com/rust-lang/rust/pull/132289#issuecomment-2564602267
2025-01-10Rollup merge of #135294 - ChrisDenton:bare-fn-width, r=jieyouxuMatthias Krüger-6/+8
Make `bare-fn-no-impl-fn-ptr-99875` test less dependent on path width This sets diagnostic-width to some arbitrary number. Seems to work on my machine.
2025-01-10Rollup merge of #135275 - coolreader18:pin-as_deref_mut-relnotes, r=BoxyUwUMatthias Krüger-0/+1
Add Pin::as_deref_mut to 1.84 relnotes Resolves #131243 - I think this got missed in the relnotes sweep or something. ``@rustbot`` label relnotes
2025-01-10Rollup merge of #134908 - madsmtm:ptr-from_ref-docs, r=ibraheemdevMatthias Krüger-2/+2
Fix `ptr::from_ref` documentation example comment The comment says that the expression involves no function call, but that was only true for the example above, the example here _does_ contain a function call. ``@rustbot`` label A-docs
2025-01-10Rollup merge of #134855 - estebank:default-field-values-unstable-docs, ↵Matthias Krüger-0/+93
r=jieyouxu Add `default_field_values` entry to unstable book Tracking issue: https://github.com/rust-lang/rust/issues/132162 RFC: https://github.com/rust-lang/rfcs/blob/master/text/3681-default-field-values.md
2025-01-10Rollup merge of #134619 - hkBst:patch-7, r=jhprattMatthias Krüger-22/+20
Improve prose around `as_slice` example of IterMut I've removed the cryptic message about not being able to call `&mut self` methods while retaining a shared borrow of the iterator, such as `as_slice` produces. This is just normal borrowing rules and does not seem especially relevant here. I can whip up a replacement if someone thinks it has value.
2025-01-10Rollup merge of #133088 - the8472:randomize-me-harder, r=workingjubileeMatthias Krüger-78/+400
`-Zrandomize-layout` harder. `Foo<T> != Foo<U>` Tracking issue: #106764 Previously randomize-layout only used a deterministic shuffle based on the seed stored in an Adt's ReprOptions, meaning that `Foo<T>` and `Foo<U>` were shuffled by the same seed. This change adds a similar seed to each calculated LayoutData so that a struct can be randomized both based on the layout of its fields and its per-type seed. Primitives start with simple seed derived from some of their properties. Though some types can no longer be distinguished at that point, e.g. usize and u64 will still be treated the same.
2025-01-10Auto merge of #135297 - flip1995:clippy-subtree-update, r=matthiaskrgrbors-436/+2004
Clippy subtree update r? `@Manishearth`
2025-01-10test that coercions still work under randomizationThe 8472-8/+40
2025-01-10also initialize Layout field in rust-analyzerThe 8472-0/+4
2025-01-10exclude unsizable tail from randomization seed calculationThe 8472-16/+13
2025-01-10adjust UI testsThe 8472-71/+248
2025-01-10Foo<T> != Foo<U> under layout randomizationThe 8472-2/+114
previously field ordering was using the same seed for all instances of Foo, now we pass seed values through the layout tree so that not only the struct itself affects layout but also its fields
2025-01-10Auto merge of #135303 - Kobzol:ci-fix-name, r=tgross35bors-4/+4
CI: fix name of jobs There is a difference between the `image` (the Dockerfile), the `name` of the job (which determines also its properties) and the `full_name`, which includes the `auto/try/pr` prefix. Missed this in https://github.com/rust-lang/rust/pull/134898.
2025-01-09Rename RegionResolutionVisitor to ScopeResolutionVisitorMichael Goulet-12/+12
2025-01-09Make sure to walk into nested const blocks in RegionResolutionVisitorMichael Goulet-4/+24
2025-01-09Add `default_field_values` entry to unstable bookEsteban Küber-0/+93
2025-01-09Add tests cases from review of #132289Frank Steffahn-0/+178
2025-01-09CI: fix name of jobsJakub Beránek-4/+4
There is a difference between the `image` (the Dockerfile), the `name` of the job (which determines also its properties) and the `full_name`, which includes the `auto/try/pr` prefix.
2025-01-09Update Cargo.lockPhilipp Krones-4/+4
2025-01-09Merge commit '19e305bb57a7595f2a8d81f521c0dd8bf854e739' into ↵Philipp Krones-432/+2000
clippy-subtree-update
2025-01-09Make bare-fn test less dependent on path widthChris Denton-6/+8
2025-01-09Rustup (#13970)Philipp Krones-46/+86
r? @ghost changelog: none
2025-01-09Bump Clippy version -> 0.1.86Philipp Krones-4/+4
2025-01-09Bump nightly version -> 2024-01-09Philipp Krones-2/+2
2025-01-09Merge remote-tracking branch 'upstream/master' into rustupPhilipp Krones-520/+2116
2025-01-09Auto merge of #135286 - matthiaskrgr:rollup-sxuq1nh, r=matthiaskrgrbors-326/+509
Rollup of 3 pull requests Successful merges: - #134898 (Make it easier to run CI jobs locally) - #135195 (Make `lit_to_mir_constant` and `lit_to_const` infallible) - #135261 (Account for identity substituted items in symbol mangling) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-09Rollup merge of #135261 - compiler-errors:coverage-has-identity-substs, ↵Matthias Krüger-39/+137
r=oli-obk Account for identity substituted items in symbol mangling See the inline comment. r? oli-obk Fixes #135235
2025-01-09Rollup merge of #135195 - oli-obk:push-toyoyrupruko, r=lcnrMatthias Krüger-175/+143
Make `lit_to_mir_constant` and `lit_to_const` infallible My motivation for this change is just that it's annoying to check everywhere, especially since all but one call site was just ICEing on errors anyway right there. They can still fail, but now just return an error constant instead of having the caller handle the error. fixes #114317 fixes #126182
2025-01-09Rollup merge of #134898 - Kobzol:ci-python-script, r=MarcoIeniMatthias Krüger-112/+229
Make it easier to run CI jobs locally This PR extends the Python CI script to perform a poor man's CI-like execution of a given CI job locally. It's not perfect, but it's better than nothing. r? `@jieyouxu`
2025-01-09Auto merge of #135268 - pietroalbini:pa-bump-stage0, r=Mark-Simulacrumbors-710/+593
Master bootstrap update Part of the release process. r? `@Mark-Simulacrum`
2025-01-09add comment to testlcnr-4/+6
2025-01-09Account for identity substituted items in symbol manglingMichael Goulet-39/+135
2025-01-09Auto merge of #135279 - matthiaskrgr:rollup-ek2qere, r=matthiaskrgrbors-36/+76
Rollup of 5 pull requests Successful merges: - #135212 (Remove outdated information in the `unreachable_pub` lint description) - #135225 (Explicitly build proc macro test with panic=unwind) - #135242 (add missing provenance APIs on NonNull) - #135247 (Add a list of symbols for stable standard library crates) - #135269 (Remove some unnecessary `.into()` calls) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-09Use option combinators instead of manual if/returnOli Scherer-10/+3
2025-01-09Remove the now-useless `Result` from `lit_to_const`Oli Scherer-47/+19
2025-01-09Always take the `Ok` path in `lit_to_const` and produce error constants insteadOli Scherer-83/+103
2025-01-09Use error constant instead of explicit error handlingOli Scherer-10/+3
2025-01-09Make `lit_to_mir_constant` infallibleOli Scherer-31/+21
2025-01-09Rollup merge of #135269 - estebank:unneeded-into, r=compiler-errorsMatthias Krüger-13/+11
Remove some unnecessary `.into()` calls
2025-01-09Rollup merge of #135247 - tgross35:stdlib-sym-list, r=oli-obkMatthias Krüger-16/+17
Add a list of symbols for stable standard library crates There are a few locations where the crate name is checked against an enumerated list of `std`, `core`, `alloc`, and `proc_macro`, or some subset thereof. In most cases when we are looking for any "standard library" crate, all four crates should be treated the same. Change this so the crates are listed in one place, and that list is used wherever a list of `std` crates is needed. `test` could be considered relevant in some of these cases, but generally treating it separate from the others seems preferable while it is unstable. There are also a few places that Clippy will be able to use this.
2025-01-09Rollup merge of #135242 - RalfJung:nonnull-provenance, r=jhprattMatthias Krüger-3/+45
add missing provenance APIs on NonNull This adds some provenance APIs that exist on raw pointers but have been forgotten on `NonNull`: ```rust impl<T> NonNull<T> { pub const fn without_provenance(addr: NonZero<usize>) -> Self; pub fn from_exposed_provenance(addr: NonZero<usize>) -> Self; } impl<T: ?Sized> NonNull<T> { pub fn expose_provenance(self) -> NonZero<usize>; } ``` https://github.com/rust-lang/libs-team/issues/518 is the ACP for the two exposed provenance ones; I forgot to include `without_provenance` there but I hope that, too, is uncontroversial (and anyway this PR only adds things unstably). Cc `@rust-lang/libs-api` Tracking issue: https://github.com/rust-lang/rust/issues/135243
2025-01-09Rollup merge of #135225 - erickt:fix-test, r=jieyouxuMatthias Krüger-1/+1
Explicitly build proc macro test with panic=unwind Fuchsia explicitly builds rust and all rust targets with `-C panic=abort` to minimize code generation size. However, when compiling a proc-macro with this setting it can cause a warning to be emitted, which breaks `tests/ui/invalid-compile-flags/crate-type-flag.rs`. This hasn't been a problem in the past for us since we compile our proc macros on host, rather than inside Fuchsia. This attempts to fix the issue by explicitly requiring that we're using the unwinder when compiling this test to avoid the warning being emitted. Fixes #135223
2025-01-09Rollup merge of #135212 - Urgau:unreach_pub-upd-descr, r=petrochenkovMatthias Krüger-3/+2
Remove outdated information in the `unreachable_pub` lint description As far as I understand the `unreachable_pub` lint hasn't had false-positives since it started using "effective visibilities". Let's remove that warning from the lint description. r? `@petrochenkov`
2025-01-09Auto merge of #133324 - scottmcm:gvn-aggregate-transmute, r=cjgillotbors-681/+1842
[mir-opt] GVN some more transmute cases We already did `Transmute`-then-`PtrToPtr`; this adds the nearly-identical `PtrToPtr`-then-`Transmute`. It also adds `transmute(Foo(x))` → `transmute(x)`, when `Foo` is a single-field transparent type. That's useful for things like `NonNull { pointer: p }.as_ptr()`. It also detects when a `Transmute` is just an identity-for-the-value `PtrCast` between different raw pointer types, to help such things fold with other GVN passes. Found these as I was looking at <https://github.com/rust-lang/compiler-team/issues/807>-related changes. This also removes the questionably-useful "turn a transmute into a field projection" part of instsimplify (which I added ages ago without an obvious need for it) since that would just put back the field projections that MCP807 is trying to ban. r? mir-opt
2025-01-09Auto merge of #135277 - matthiaskrgr:rollup-0k61sf8, r=matthiaskrgrbors-159/+739
Rollup of 6 pull requests Successful merges: - #128110 (Suggest Replacing Comma with Semicolon in Incorrect Repeat Expressions) - #134609 (Add new `{x86_64,i686}-win7-windows-gnu` targets) - #134875 (Implement `const Destruct` in old solver) - #135221 (Include rustc and rustdoc book in replace-version-placeholder) - #135231 (bootstrap: Add more comments to some of the test steps) - #135256 (Move `mod cargo` below the import statements) Failed merges: - #135195 (Make `lit_to_mir_constant` and `lit_to_const` infallible) r? `@ghost` `@rustbot` modify labels: rollup