about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorLines
2025-01-08Auto merge of #135207 - lnicola:sync-from-ra, r=lnicolabors-5399/+32947
Subtree update of `rust-analyzer` r? `@ghost`
2025-01-07Auto merge of #135218 - matthiaskrgr:rollup-xngklx8, r=matthiaskrgrbors-181/+301
Rollup of 6 pull requests Successful merges: - #133810 (remove unnecessary `eval_verify_bound`) - #134745 (Normalize each signature input/output in `typeck_with_fallback` with its own span) - #134989 (Lower Guard Patterns to HIR.) - #135149 (Use a post-monomorphization typing env when mangling components that come from impls) - #135171 (rustdoc: use stable paths as preferred canonical paths) - #135200 (rustfmt: drop nightly-gating of the `--style-edition` flag registration) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-07Rollup merge of #135200 - jieyouxu:stabilize-style-edition, ↵Matthias Krüger-6/+6
r=ytmimi,compiler-errors rustfmt: drop nightly-gating of the `--style-edition` flag registration Follow-up to [Stabilize `style_edition = "2024"` in-tree #134929](https://github.com/rust-lang/rust/pull/134929). #134929 un-nightly-gated the *read* of `--style-edition`, but didn't also un-nightly-gate the *registration*/*declaration* of the `--style-edition` flag itself. Reading `--style-edition` on a non-nightly channel (e.g. beta) will thus panic because `--style-edition` is never declared. This PR also un-nightly-gates the registration. Not sure how to write a regression test for this, because this *requires* the non-nightly / beta channel. Though existing tests do fail (albeit indirectly). Checking if this fixes the panic against beta in https://github.com/rust-lang/rust/pull/135197. r? rustfmt
2025-01-07Rollup merge of #135171 - notriddle:notriddle/stable-path-is-better, ↵Matthias Krüger-1/+47
r=GuillaumeGomez rustdoc: use stable paths as preferred canonical paths This accomplishes something like 16a4ad7d7b0d163f7be6803c786c3b83d42913bb, but with the `rustc_allowed_through_unstable_modules` attribute instead of the path length. Fixes #131676
2025-01-07Rollup merge of #135149 - compiler-errors:mangle, r=oli-obkMatthias Krüger-38/+99
Use a post-monomorphization typing env when mangling components that come from impls When mangling associated methods of impls, we were previously using the wrong param-env. Instead of using a fully monomorphized param-env like we usually do in codegen, we were taking the post-analysis param-env, and treating it as an early binder to *re-substitute* the impl args. I've pointed out the problematic old code in an inline comment. This would give us param-envs with possibly trivial predicates that would prevent normalization via param-env shadowing. In the example test linked below, `tests/ui/symbol-names/normalize-in-param-env.rs`, this happens when we mangle the impl `impl<P: Point2> MyFrom<P::S> for P` with the substitution `P = Vec2`. Because the where clause of the impl is `P: Point2`, which elaborates to `[P: Point2, P: Point, <P as Point>::S projects-to <P as Point2>::S2]` and the fact that `impl Point2 for Vec2` normalizes `Vec2::S2` to `Vec2::S`, this causes a cycle. The proper fix here is to use a fully monomorphized param-env for the case where the impl is properly substituted. Fixes #135143 While #134081 uncovered this bug for legacy symbol mangling, it was preexisting for v0 symbol mangling. This PR fixes both. The test requires a "hack" because we strip the args of the instance we're printing for legacy symbol mangling except for drop glue, so we box a closure to ensure we generate drop glue. r? oli-obk
2025-01-07Rollup merge of #134989 - max-niederman:guard-patterns-hir, r=oli-obkMatthias Krüger-41/+72
Lower Guard Patterns to HIR. Implements lowering of [guard patterns](https://rust-lang.github.io/rfcs/3637-guard-patterns.html) (see the [tracking issue](#129967)) to HIR.
2025-01-07Rollup merge of #134745 - compiler-errors:better-arg-span-in-typeck, r=BoxyUwUMatthias Krüger-77/+69
Normalize each signature input/output in `typeck_with_fallback` with its own span Applies the same hack as #106582 but to the args in typeck. Greatly improves normalization error spans from a signature.
2025-01-07Rollup merge of #133810 - lcnr:remove-verify_bound, r=compiler-errorsMatthias Krüger-18/+8
remove unnecessary `eval_verify_bound` This does not impact any tests. I feel like any cases where this could useful should instead be fixed by a general improvement to `eval_verify_bound` to avoid having to promote this `TypeTest` in the first place :thinking: r? types cc ``@nikomatsakis``
2025-01-07Merge pull request #18874 from lnicola/sync-from-rustLaurențiu Nicola-9761/+378307
minor: Sync from downstream
2025-01-07Merge from rust-lang/rustLaurențiu Nicola-9760/+378306
2025-01-07Preparing for merge from rust-lang/rustLaurențiu Nicola-1/+1
2025-01-07Auto merge of #135202 - GuillaumeGomez:rollup-9xgs39t, r=GuillaumeGomezbors-96/+148
Rollup of 9 pull requests Successful merges: - #135081 (bootstrap: Build jemalloc with support for 64K pages) - #135174 ([AIX] Port test case run-make/reproducible-build ) - #135177 (llvm: Ignore error value that is always false) - #135182 (Transmute from NonNull to pointer when elaborating a box deref (MCP807)) - #135187 (apply a workaround fix for the release roadblock) - #135189 (Remove workaround from pull request template) - #135193 (don't bless `proc_macro_deps.rs` unless it's necessary) - #135198 (Avoid naming variables `str`) - #135199 (Eliminate an unnecessary `Symbol::to_string`; use `as_str`) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-07Rollup merge of #135199 - joshtriplett:unnecessary-to-string, r=lqdGuillaume Gomez-5/+4
Eliminate an unnecessary `Symbol::to_string`; use `as_str`
2025-01-07Rollup merge of #135198 - joshtriplett:str-is-a-type, r=jieyouxuGuillaume Gomez-34/+34
Avoid naming variables `str` This renames variables named `str` to other names, to make sure `str` always refers to a type. It's confusing to read code where `str` (or another standard type name) is used as an identifier. It also produces misleading syntax highlighting.
2025-01-07Rollup merge of #135193 - onur-ozkan:tidy-cache-invalidation, r=jieyouxuGuillaume Gomez-7/+10
don't bless `proc_macro_deps.rs` unless it's necessary Running tidy with `--bless` flag is breaking the build cache as tidy updates mtime of `proc_macro_deps.rs` (https://github.com/rust-lang/rust/pull/134865) unconditionally and that leads cargo to recompile tidy. This patch fixes that.
2025-01-07Rollup merge of #135189 - Urgau:triagebot-html-ignored, r=lqdGuillaume Gomez-1/+1
Remove workaround from pull request template This PR removes the workaround (`\`) from our pull request template as triagebot/rustbot now ignores HTML blocks. cf. https://github.com/rust-lang/triagebot/pull/1869 cc `@jieyouxu` r? `@ehuss`
2025-01-07Rollup merge of #135187 - onur-ozkan:release-fix, r=pietroalbiniGuillaume Gomez-1/+12
apply a workaround fix for the release roadblock This has been a problem since the last two releases. r? pietroalbini
2025-01-07Rollup merge of #135182 - scottmcm:box-deref-via-transmute, r=oli-obkGuillaume Gomez-28/+29
Transmute from NonNull to pointer when elaborating a box deref (MCP807) Since per https://github.com/rust-lang/compiler-team/issues/807 we have to stop projecting into `NonNull`. cc https://github.com/rust-lang/rust/issues/133652
2025-01-07Rollup merge of #135177 - maurer:rename-module, r=nikicGuillaume Gomez-17/+5
llvm: Ignore error value that is always false See llvm/llvm-project#121851 For LLVM 20+, this function (`renameModuleForThinLTO`) has no return value. For prior versions of LLVM, this never failed, but had a signature which allowed an error value people were handling. `@rustbot` label: +llvm-main r? `@nikic` Wait a moment before approving while the llvm-main infrastructure picks it up.
2025-01-07Rollup merge of #135174 - xingxue-ibm:reproducible-build-aix, r=jieyouxuGuillaume Gomez-3/+44
[AIX] Port test case run-make/reproducible-build The test case `run-make/reproducible-build` verifies that two identical invocations of the compiler produce the same output by comparing the linker arguments, resulting binaries, and other artifacts. However, the AIX linker command includes an argument that specifies the file containing exported symbols, with a file path that contains a randomly generated substring to prevent collisions between different linking processes. Additionally, the AIX XCOFF file header includes a 4-byte timestamp. This PR replaces the random substring with a placeholder and nullifies the timestamp field in the XCOFF files for the comparisons.
2025-01-07Rollup merge of #135081 - mrkajetanp:jemalloc-64k, r=KobzolGuillaume Gomez-0/+9
bootstrap: Build jemalloc with support for 64K pages By default, jemalloc is built to only support the same page size as the host machine. Set an env variable so that jemalloc is built with support for page sizes up to 64K regardless of the host machine. r? `@Kobzol` Resolves #134563 Potentially resolves #133748 (needs verification) ---- Results from local rustc-perf testing below, within 0.5% on every metric except max-rss. AArch64: ![Screenshot 2025-01-03 at 5 53 13 pm](https://github.com/user-attachments/assets/71705c59-7d7b-4753-a184-8c784233e603) x86_64: ![Screenshot 2025-01-03 at 5 54 16 pm](https://github.com/user-attachments/assets/ea28aded-3b90-43f4-a965-b081b07b95ab)
2025-01-07Merge pull request #18870 from Veykril/push-vnpsptpolyolLukas Wirth-5/+0
Drop unnecessary tracing::warn
2025-01-07Merge pull request #18867 from Veykril/push-ntmxlropxkrrLukas Wirth-102/+191
internal: target-triple -> target-tuple + version fetching cleanup
2025-01-07Drop unnecessary tracing::warnLukas Wirth-5/+0
We already emit an error
2025-01-07Add some smoke tests to toolchain_infoLukas Wirth-23/+129
2025-01-07Align toolchain version fetching with other toolchain info queryingLukas Wirth-110/+93
Fix --target flag argument order in rustc_cfg fetching
2025-01-07target-triple -> target-tupleLukas Wirth-17/+17
2025-01-07Merge pull request #18788 from Veykril/push-zxystwnotuvqLukas Wirth-252/+159
Remove `rust-analyzer.cargo.sysrootQueryMetadata` config again
2025-01-07Remove `rust-analyzer.cargo.sysrootQueryMetadata` config againLukas Wirth-252/+159
2025-01-07rustfmt: drop nightly-gating of the `--style-edition` flag registration许杰友 Jieyou Xu (Joe)-6/+6
2025-01-07Avoid naming variables `str`Josh Triplett-34/+34
This renames variables named `str` to other names, to make sure `str` always refers to a type. It's confusing to read code where `str` (or another standard type name) is used as an identifier. It also produces misleading syntax highlighting.
2025-01-07Eliminate an unnecessary `Symbol::to_string`; use `as_str`Josh Triplett-5/+4
2025-01-07Merge pull request #18864 from alexkirsz/alexkirsz/fix-diagnostics-clearingLukas Wirth-0/+14
fix: Fix diagnostics not clearing between flychecks
2025-01-07Merge pull request #18832 from vishruth-thimmaiah/fix_string_compChayim Refael Friedman-1/+72
fix: do not offer completions within macro strings
2025-01-07Merge pull request #18866 from bobozaur/fix-fetching-on-buildfile-changesLukas Wirth-10/+10
Fix JSON project `PackageRoot` buildfile inclusion
2025-01-07project-model: fix JSON project PackageRoot buildfile inclusionBogdan Mircea-10/+10
2025-01-07fix: do not offer completions within macro stringsVishruth-Thimmaiah-1/+72
2025-01-07lintAlex Kirszenberg-8/+6
2025-01-07fix: Fix diagnostics not clearing between flychecksAlex Kirszenberg-0/+16
2025-01-07don't bless `proc_macro_deps.rs` unless it's necessaryonur-ozkan-7/+10
Running tidy with `--bless` flag is breaking the build cache as tidy updates mtime of `proc_macro_deps.rs` unconditionally and that leads cargo to recompile tidy. This patch fixes that. Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-07Merge pull request #18862 from lnicola/publish-test-utilsLaurențiu Nicola-1/+1
minor: Set test-utils dependency version, since it's now published
2025-01-07Set test-utils dependency version, since it's now being publishedLaurențiu Nicola-1/+1
2025-01-07Auto merge of #135173 - pietroalbini:pa-fix-rvp, r=workingjubileebors-7/+7
Avoid replacing the definition of `CURRENT_RUSTC_VERSION` Before this PR, replace-version-placeholder hardcoded the path defining CURRENT_RUSTC_VERSION (to avoid replacing it). After a refactor moved the file defining it without changing the hardcoded path, the tool started replacing the constant itself with the version number. To avoid this from happening in the future, this changes the definition of the constant to avoid the tool from ever matching it. r? `@workingjubilee`
2025-01-07Merge pull request #18853 from ChayimFriedman2/no-completionLaurențiu Nicola-5/+105
Fix case where completion inside macro that expands to `#[test]` was unavailable
2025-01-07Remove workaround from pull request templateUrgau-1/+1
as triagebot/rustbot now ignores HTML blocks. cf. https://github.com/rust-lang/triagebot/pull/1869
2025-01-07apply a workaround fix for the release blocker issueonur-ozkan-1/+12
Signed-off-by: onur-ozkan <work@onurozkan.dev>
2025-01-06bootstrap: Build jemalloc for AArch64 with support for 64K pagesKajetan Puchalski-0/+9
By default, jemalloc is built to only support the same page size as the host machine. For AArch64 targets, set an env variable so that jemalloc is built with support for page sizes up to 64K regardless of the host machine.
2025-01-07Auto merge of #135183 - jhpratt:rollup-qwg4pm0, r=jhprattbors-123/+812
Rollup of 9 pull requests Successful merges: - #131830 (Add support for wasm exception handling to Emscripten target) - #132345 (Improve diagnostics for `HostEffectPredicate` in the new solver) - #134568 (Release notes for 1.84.0) - #134744 (Don't ice on bad transmute in typeck in new solver) - #135090 (Suggest to replace tuple constructor through projection) - #135116 (rustdoc: Fix mismatched capitalization in sidebar) - #135126 (mark deprecated option as deprecated in rustc_session to remove copypasta and small refactor) - #135139 ([generic_assert] Constify methods used by the formatting system) - #135170 (Update triagebot.toml: celinval vacation is over) r? `@ghost` `@rustbot` modify labels: rollup
2025-01-06Rollup merge of #135170 - celinval:chores-vacation-end, r=jieyouxuJacob Pratt-2/+1
Update triagebot.toml: celinval vacation is over I'm also removing myself from the MIR syntax changes notifications.
2025-01-06Rollup merge of #135139 - c410-f3r:8-years-rfc, r=jhprattJacob Pratt-31/+11
[generic_assert] Constify methods used by the formatting system cc #44838 Starts the "constification" of all the elements required to allow the execution of the formatting system in constant environments. ```rust const _: () = { panic!("{:?}", 1i32); }; ``` Further stuff is blocked by #133999.