Commit graph

302843 commits

Author SHA1 Message Date
Laurențiu Nicola
3d16f1ca40
Merge pull request #20450 from Wilfred/update_vsce
[internal] Update to the latest @vscode/vsce for extension build
2025-08-13 14:47:20 +00:00
Wilfred Hughes
8ef6a8ff6d [internal] Update to the latest @vscode/vsce for extension build
This isn't a logic change, but it fixes an npm warning during the
build. vsce itself hasn't had any major changes between 3.2.2 and 3.6.

* https://github.com/microsoft/vscode-vsce/releases/tag/v3.3.0
* https://github.com/microsoft/vscode-vsce/releases/tag/v3.4.0
* https://github.com/microsoft/vscode-vsce/releases/tag/v3.5.0
* https://github.com/microsoft/vscode-vsce/releases/tag/v3.6.0
2025-08-13 15:25:34 +01:00
Lukas Wirth
b7e4b28c3b
Merge pull request #20446 from lcnr/kinda-unhelpful-3
next-solver fun time
2025-08-13 10:17:53 +00:00
lcnr
67b1e32908 manually normalize alias 2025-08-13 11:00:00 +02:00
lcnr
5849fef132 layout_of uses PostAnalysis 2025-08-13 10:57:45 +02:00
lcnr
00941b3142 implement type_of_opaque 2025-08-13 10:57:45 +02:00
Lukas Wirth
9b089011a0
Merge pull request #20376 from fee1-dead/traitalias
Merge Trait and TraitAlias handling
2025-08-13 08:27:54 +00:00
Lukas Wirth
178007c0fd
Merge pull request #20445 from rust-lang/veykril/push-twmmuyzwtxno
fix: Attach db for inlay hint compute
2025-08-13 08:01:19 +00:00
lcnr
39ac6e1eed update a few fixmes, and one trivial improvement 2025-08-13 10:01:17 +02:00
Lukas Wirth
0387ecb5d4
Merge pull request #20444 from rust-lang/veykril/push-snuuupqnrqzx
minor: Print fields of interned IDs in hir-ty instead of just the ID
2025-08-13 07:50:15 +00:00
Lukas Wirth
4bbbe6ee2b fix: Attach db for inlay hint compute 2025-08-13 09:42:50 +02:00
Deadbeef
b62116bda7 fix errors after rebase 2025-08-13 15:33:08 +08:00
Lukas Wirth
2a509717b4 Fix metrics checking out repos into toplevel folder instead of target 2025-08-13 09:31:03 +02:00
Lukas Wirth
b416845683 Print fields of interned IDs in hir-ty instead of just the ID 2025-08-13 09:29:04 +02:00
Deadbeef
0d2f8aff1b add test for trait alias projections 2025-08-13 15:28:08 +08:00
Deadbeef
8d247472e5 Merge Trait and TraitAlias handling 2025-08-13 15:28:08 +08:00
Lukas Wirth
6e4644fd31
Merge pull request #20329 from jackh726/next-trait-solver-querify
Switch from Chalk to the next trait solver
2025-08-13 06:10:45 +00:00
Chayim Refael Friedman
40b8d41367
Merge pull request #20432 from sgasho/fix/20215_implement_default_member_to_resolve_ident_pat
Fix "Implement default members" to resolve IdentPat
2025-08-12 13:18:36 +00:00
sgasho
875c158686 fix: Implement default member to resolve IdentPat 2025-08-12 21:53:50 +09:00
Shoyu Vanilla (Flint)
c14814cb66
Merge pull request #20434 from ShoyuVanilla/diag-fix-again
fix: Panic while trying to clear old diagnostics while there's nothing
2025-08-11 15:35:38 +00:00
Shoyu Vanilla
6c3c620e6b fix: Panic while trying to clear old diagnostics while there's nothing 2025-08-12 00:24:44 +09:00
Chayim Refael Friedman
2e4c8e2b66
Merge pull request #20420 from iorizu/doc-symbols-filter
feat: Add Config Option to Exclude Locals from Document Symbol Search
2025-08-11 14:46:18 +00:00
Lukas Wirth
1b5dbd9dfa
Merge pull request #20429 from ShoyuVanilla/master
hotfix: Update flycheck diagnostics generation
2025-08-11 09:31:31 +00:00
Shoyu Vanilla (Flint)
7daaa4ee01
hotfix: Update flycheck diagnostics generation 2025-08-11 18:18:55 +09:00
Laurențiu Nicola
6bb9af0eeb
Merge pull request #20424 from rust-lang/rustc-pull
Rustc pull update
2025-08-11 06:58:04 +00:00
The rustc-josh-sync Cronjob Bot
0585bdff8b Merge ref '21a19c297d' from rust-lang/rust
Pull recent changes from https://github.com/rust-lang/rust via Josh.

Upstream ref: 21a19c297d
Filtered ref: 9a5c1fb93028e1a29a7598ce782efb0c5d7be534

This merge was created using https://github.com/rust-lang/josh-sync.
2025-08-11 04:30:34 +00:00
The rustc-josh-sync Cronjob Bot
af10cb727f Prepare for merging from rust-lang/rust
This updates the rust-version file to 21a19c297d.
2025-08-11 04:25:52 +00:00
bors
21a19c297d Auto merge of #135846 - estebank:non-exhaustive-dfv-ctor-2, r=BoxyUwU
Detect struct construction with private field in field with default

When trying to construct a struct that has a public field of a private type, suggest using `..` if that field has a default value.

```
error[E0603]: struct `Priv1` is private
  --> $DIR/non-exhaustive-ctor-2.rs:19:39
   |
LL |     let _ = S { field: (), field1: m::Priv1 {} };
   |                            ------     ^^^^^ private struct
   |                            |
   |                            while setting this field
   |
note: the struct `Priv1` is defined here
  --> $DIR/non-exhaustive-ctor-2.rs:14:4
   |
LL |    struct Priv1 {}
   |    ^^^^^^^^^^^^
help: the type `Priv1` of field `field1` is private, but you can construct the default value defined for it in `S` using `..` in the struct initializer expression
   |
LL |     let _ = S { field: (), .. };
   |                            ~~
```
2025-08-10 23:47:25 +00:00
Ifeanyi Orizu
00d000ce74 Fix minor things 2025-08-10 17:48:17 -05:00
Ifeanyi Orizu
802fa9255b Add config option to exclude locals from doc search 2025-08-10 17:48:17 -05:00
bors
c8ca44c98e Auto merge of #145223 - jhpratt:rollup-xcqbwqe, r=jhpratt
Rollup of 7 pull requests

Successful merges:

 - rust-lang/rust#144553 (Rehome 32 `tests/ui/issues/` tests to other subdirectories under `tests/ui/`)
 - rust-lang/rust#145064 (Add regression test for `saturating_sub` bounds check issue)
 - rust-lang/rust#145121 (bootstrap: `x.py dist rustc-src` should keep LLVM's siphash)
 - rust-lang/rust#145150 (Replace unsafe `security_attributes` function with safe `inherit_handle` alternative)
 - rust-lang/rust#145152 (Use `eq_ignore_ascii_case` to avoid heap alloc in `detect_confuse_type`)
 - rust-lang/rust#145200 (mbe: Fix typo in attribute tracing)
 - rust-lang/rust#145222 (Fix typo with paren rustc_llvm/build.rs)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-08-10 20:44:38 +00:00
Jacob Pratt
c9847db07e
Rollup merge of #145222 - dpaoliello:pareninllvmbuild, r=Amanieu
Fix typo with paren rustc_llvm/build.rs

The current parenthesis looks suspect: it means that OpenHarmony is always excluded whereas it looks like it was intended to only be excluded if the architecture was Arm.

Since Rust doesn't support the other architectures with OpenHarmony, there currently isn't a bug but this cleans up some suspicious code and avoids a potential future annoyance for someone trying to bring up a new triple.

r? `@Amanieu`
2025-08-10 15:43:56 -04:00
Jacob Pratt
a164527df7
Rollup merge of #145200 - joshtriplett:mbe-typo-fix, r=lqd
mbe: Fix typo in attribute tracing
2025-08-10 15:43:55 -04:00
Jacob Pratt
733568ac7d
Rollup merge of #145152 - xizheyin:detect-confusion-type, r=lqd
Use `eq_ignore_ascii_case` to avoid heap alloc in `detect_confuse_type`

A small optimization has been made, using `to_ascii_lowercase()` instead of `to_lowercase().to_string()`.

r? compiler
2025-08-10 15:43:55 -04:00
Jacob Pratt
adf522cefb
Rollup merge of #145150 - ChrisDenton:inherit, r=Mark-Simulacrum
Replace unsafe `security_attributes` function with safe `inherit_handle` alternative

The `security_attributes` function is marked as safe despite taking a raw pointer which will later be used. Fortunately this function is only used internally and only in one place that has been basically the same for a decade now. However, we only ever set one bool so it's easy enough to replace with something that's actually safe.

In the future we might want to expose the ability for users to set security attributes. But that should be properly designed (and safe!).
2025-08-10 15:43:54 -04:00
Jacob Pratt
92bdf9e8ee
Rollup merge of #145121 - lambdageek:dist-must-keep-llvm-third-party-siphash, r=Kobzol
bootstrap: `x.py dist rustc-src` should keep LLVM's siphash

Fixes rust-lang/rust#145117
2025-08-10 15:43:54 -04:00
Jacob Pratt
a7a4e17225
Rollup merge of #145064 - okaneco:saturating_sub_regression_tests, r=nikic
Add regression test for `saturating_sub` bounds check issue

Add codegen test for issue where `valid_index.saturating_sub(X)` produced an extra bounds check.
This was fixed by the LLVM upgrade.

Closes rust-lang/rust#139759
2025-08-10 15:43:53 -04:00
Jacob Pratt
5bd4e832d3
Rollup merge of #144553 - Oneirical:uncountable-integer-4, r=jieyouxu
Rehome 32 `tests/ui/issues/` tests to other subdirectories under `tests/ui/`

rust-lang/rust#143902 divided into smaller, easier to review chunks.

Part of rust-lang/rust#133895

Methodology:

1. Refer to the previously written `tests/ui/SUMMARY.md`
2. Find an appropriate category for the test, using the original issue thread and the test contents.
3. Add the issue URL at the bottom (not at the top, as that would mess up stderr line numbers)
4. Rename the tests to make their purpose clearer

Inspired by the methodology that `@Kivooeo` was using.

r? `@jieyouxu`
2025-08-10 15:43:52 -04:00
Daniel Paoliello
a71b024c89 Fix typo with paren rustc_llvm/build.rs 2025-08-10 12:22:13 -07:00
Esteban Küber
29d26f27a6 review comments 2025-08-10 19:15:20 +00:00
Esteban Küber
464a6b1b4a Detect struct construction with private field in field with default
When trying to construct a struct that has a public field of a private type, suggest using `..` if that field has a default value.

```
error[E0603]: struct `Priv1` is private
  --> $DIR/non-exhaustive-ctor.rs:25:39
   |
LL |     let _ = S { field: (), field1: m::Priv1 {} };
   |                            ------     ^^^^^ private struct
   |                            |
   |                            while setting this field
   |
note: the struct `Priv1` is defined here
  --> $DIR/non-exhaustive-ctor.rs:14:4
   |
LL |    struct Priv1 {}
   |    ^^^^^^^^^^^^
help: the field `field1` you're trying to set has a default value, you can use `..` to use it
   |
LL |     let _ = S { field: (), .. };
   |                            ~~
```
2025-08-10 19:15:18 +00:00
bors
29737cb44b Auto merge of #144544 - JonathanBrouwer:illformed-in-deps, r=traviscross
Start reporting future breakage for `ILL_FORMED_ATTRIBUTE_INPUT` in dependencies

This has been a warn lint since early 2019 and a deny-by-default lint since late 2019.
We're currently transitioning some of the cases where this lint is being produced to a hard error (https://github.com/rust-lang/rust/pull/143607 https://github.com/rust-lang/rust/pull/143808 and more)
So let's report this lint in all dependencies for the remaining attributes

r? `@traviscross`
`@rustbot` labels +I-lang-nominated +T-lang -T-compiler
cc `@jdonszelmann`

(Separate question: Why does the "Future incompatibility report" only trigger if `report_in_deps` is true, even if the future incompatibility happens in the same crate, is this correct?)

This also needs a crater run, but I don't have permissions to trigger this
2025-08-10 17:44:40 +00:00
Oneirical
aa543963c6 Rehome tests/ui/issues/ tests [4/?] 2025-08-10 11:54:15 -04:00
bors
18eeac04fc Auto merge of #145210 - Zalathar:rollup-dm4reb2, r=Zalathar
Rollup of 17 pull requests

Successful merges:

 - rust-lang/rust#141624 (unstable-book: Add stubs for environment variables; document some of the important ones)
 - rust-lang/rust#143093 (Simplify polonius location-sensitive analysis)
 - rust-lang/rust#144402 (Stabilize loongarch32 inline asm)
 - rust-lang/rust#144403 (`tests/ui/issues/`: The Issues Strike Back [4/N])
 - rust-lang/rust#144739 (Use new public libtest `ERROR_EXIT_CODE` constant in rustdoc)
 - rust-lang/rust#145089 (Improve error output when a command fails in bootstrap)
 - rust-lang/rust#145112 ([win][arm64ec] Partial fix for raw-dylib-link-ordinal on Arm64EC)
 - rust-lang/rust#145129 ([win][arm64ec] Add `/machine:arm64ec` when linking LLVM as Arm64EC)
 - rust-lang/rust#145130 (improve "Documentation problem" issue template.)
 - rust-lang/rust#145135 (Stabilize `duration_constructors_lite` feature)
 - rust-lang/rust#145145 (some `derive_more` refactors)
 - rust-lang/rust#145147 (rename `TraitRef::from_method` to `from_assoc`)
 - rust-lang/rust#145156 (Override custom Cargo `build-dir` in bootstrap)
 - rust-lang/rust#145160 (Change days-threshold to 28 in [behind-upstream])
 - rust-lang/rust#145162 (`{BTree,Hash}Map`: add "`Entry` API" section heading)
 - rust-lang/rust#145187 (Fix an unstable feature comment that wasn't a doc comment)
 - rust-lang/rust#145191 (`suggest_borrow_generic_arg`: use the correct generic args)

r? `@ghost`
`@rustbot` modify labels: rollup
2025-08-10 14:17:41 +00:00
Shoyu Vanilla (Flint)
bd46f7b6ae
Merge pull request #20419 from ShoyuVanilla/flyck-gen
internal: Make flycheck generational
2025-08-10 14:00:52 +00:00
Shoyu Vanilla
b9f2bb7dd1 internal: Make flycheck generational 2025-08-10 22:10:55 +09:00
Stuart Cook
934cb10f1b
Rollup merge of #145191 - dianne:fix-borrow-suggestion-args, r=compiler-errors
`suggest_borrow_generic_arg`: use the correct generic args

The suggestion now gets calls' generic arguments from the callee's type to handle cases where the callee isn't an identifier expression. Fixes rust-lang/rust#145164.
2025-08-10 19:45:56 +10:00
Stuart Cook
94b344d1af
Rollup merge of #145187 - joshtriplett:fix-unstable-feature-comment, r=lqd
Fix an unstable feature comment that wasn't a doc comment

Every other feature in the list uses a doc comment; fix one that used a regular comment to use a doc comment.
2025-08-10 19:45:55 +10:00
Stuart Cook
461009dc93
Rollup merge of #145162 - ada4a:hash_and_btree_map-add-entry-section, r=joshtriplett
`{BTree,Hash}Map`: add "`Entry` API" section heading

I wanted to link to an introduction of the `Entry` API to the help message of `clippy::map_entry` (see https://github.com/rust-lang/rust-clippy/issues/11598 for motivation), but I found the documentation on the `Entry` enum itself a bit short. On the other hand, `{BTree,Hash}Map` both have sections in their docs introducing the whole API and giving usage examples, and so I would like to link to that instead. For that, I introduce the "`Entry` API" section heading to both of them.

Do let me know whether you think this is the right approach.
2025-08-10 19:45:54 +10:00
Stuart Cook
a4acb8aafa
Rollup merge of #145160 - xizheyin:behind-upstream, r=Urgau
Change days-threshold to 28 in [behind-upstream]

Make the days-threshold to 28 to reduce false positives.

[#triagebot > Outdated commit message](https://rust-lang.zulipchat.com/#narrow/channel/224082-triagebot/topic/Outdated.20commit.20message)

r? ``````@Urgau``````

cc ``````@jieyouxu``````
2025-08-10 19:45:54 +10:00