Commit graph

37340 commits

Author SHA1 Message Date
Chayim Refael Friedman
87cf6631c6
Merge pull request #21265 from J3m3/lint-attr-order
Some checks failed
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
release / dist (aarch64-apple-darwin) (push) Has been cancelled
release / dist (x86_64-apple-darwin) (push) Has been cancelled
release / dist (aarch64-unknown-linux-gnu) (push) Has been cancelled
release / dist (arm-unknown-linux-gnueabihf) (push) Has been cancelled
release / dist (x86_64-unknown-linux-gnu) (push) Has been cancelled
release / dist (aarch64-pc-windows-msvc) (push) Has been cancelled
release / dist (x86_64-unknown-linux-musl) (push) Has been cancelled
autopublish / publish (push) Has been cancelled
release / dist (x86_64-pc-windows-msvc) (push) Has been cancelled
release / dist (i686-pc-windows-msvc) (push) Has been cancelled
release / publish (push) Has been cancelled
fix: respect rustc's lint attribute application order
2025-12-14 22:33:33 +00:00
Lukas Wirth
c410127c69
Merge pull request #21225 from Veykril/push-wpzrmoxzttuz
internal: Give `FileSymbol` it's `'db` lifetime
2025-12-14 10:04:46 +00:00
Lukas Wirth
0da7839f48 internal: Give FileSymbol it's 'db lifetime 2025-12-14 10:54:13 +01:00
Lukas Wirth
7c063a52fc
Merge pull request #21264 from A4-Tacks/bind-unused-not-applicable-on-closure
Fix bind_unused_param applicable on closure
2025-12-14 09:13:41 +00:00
Lukas Wirth
67db7568e5
Merge pull request #21257 from Veykril/push-qnolwwkvuwxk
minor: Emit `WorkspaceDiagnosticRefresh` when flycheck finished
2025-12-14 09:05:23 +00:00
Lukas Wirth
4576663053
Merge pull request #21253 from tris203/lsp_didSave
fix(lsp): handle dynamic registration for didSave
2025-12-14 08:56:11 +00:00
Lukas Wirth
3276659861 minor: Emit WorkspaceDiagnosticRefresh when flycheck finished 2025-12-14 09:54:59 +01:00
Jesung Yang
2619bd2cec fix: respect rustc's lint attribute application order
Reverse the order of returned lint attributes for a `SyntaxNode` to
match rustc's behavior.

When multiple lint attributes are present, rustc overrides earlier ones
with the last defined attribute. The previous iteration order was
incorrect, causing earlier attributes to override the later ones.
2025-12-14 06:30:09 +00:00
A4-Tacks
1b3ae5fba1
Fix bind_unused_param applicable on closure
Example
---
```rust
fn foo() {
    let _ = |$0x| 2;
}
```

**Before this PR**

```rust
fn foo() {
    let _ = x;
    let _ = |x| 2;
}
```

**After this PR**

Assist not applicable
2025-12-14 07:43:54 +08:00
Chayim Refael Friedman
ec884b3251
Merge pull request #21263 from ChayimFriedman2/format-args-args
Some checks failed
metrics / build_metrics (push) Has been cancelled
metrics / other_metrics (diesel-1.4.8) (push) Has been cancelled
metrics / other_metrics (hyper-0.14.18) (push) Has been cancelled
metrics / other_metrics (ripgrep-13.0.0) (push) Has been cancelled
metrics / other_metrics (self) (push) Has been cancelled
metrics / other_metrics (webrender-2022) (push) Has been cancelled
metrics / generate_final_metrics (push) Has been cancelled
internal: Use a generated name in old format_args lowering, instead of `args`
2025-12-13 18:21:51 +00:00
Chayim Refael Friedman
84a306aa1e Use a generated name in old format_args lowering, instead of args
To prevent it from clashing with other names.
2025-12-13 20:12:08 +02:00
Lukas Wirth
eda27bbce0
Merge pull request #21242 from ChayimFriedman2/fmt-fix
Some checks failed
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Has been cancelled
fix: Support the new lowering of `format_args!()`
2025-12-12 17:45:43 +00:00
Lukas Wirth
55026408c5
Merge pull request #21251 from ChayimFriedman2/fix-typebound-kind
fix: Fix a panic in `ast::TypeBound::kind()`
2025-12-12 17:43:59 +00:00
Chayim Refael Friedman
16603f8797
Merge pull request #21256 from A4-Tacks/big-range-add-ret-type
Reorder add_return_type assist
2025-12-12 13:09:16 +00:00
A4-Tacks
5d1e81e157
Reorder add_return_type assist
This assist is often before inline and is very inconvenient

Usually, incomplete expression statements are written at the tail of the block, but they are not the return value of the block

```rust
fn foo() {
    Some(2).$0and(optb)
}
```

```text
1. Add this function's return type
2. Inline `and`
3. Qualify `and` method call
4. Replace and with and_then
```
2025-12-12 20:59:41 +08:00
Shoyu Vanilla (Flint)
9cb9b1b385
Merge pull request #20754 from A4-Tacks/conv-for-while-loop-label-attr
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Fix loses label for convert_for_to_while_let
2025-12-12 11:46:18 +00:00
tris203
17d03b90b4
fix(lsp): handle dynamic registration for didSave
Update server capabilities to set `save` to `None` when the client supports
dynamic registration for `didSaveTextDocument`. This prevents redundant
static registration and aligns with LSP specification.
2025-12-12 07:41:36 +00:00
Chayim Refael Friedman
459982c158 Fix a panic in ast::TypeBound::kind() 2025-12-12 00:45:37 +02:00
Chayim Refael Friedman
f5a83fb3b5
Merge pull request #21252 from ChayimFriedman2/fix-clippy
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
internal: Fix Clippy
2025-12-11 22:19:48 +00:00
Chayim Refael Friedman
54a778a371 Fix Clippy
Needed because there is a new Clippy - Rust 1.92.0 was released.
2025-12-12 00:09:31 +02:00
Shoyu Vanilla (Flint)
a3f0193986
Merge pull request #21239 from A4-Tacks/eager-param-and-paren
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Fix assist `and` -> `and_then` parameter
2025-12-11 10:47:12 +00:00
Shoyu Vanilla (Flint)
3e3f994af8
Merge pull request #21243 from ChayimFriedman2/assoc-defaults
feat: Support `#[feature(associated_type_defaults)]`
2025-12-11 10:43:37 +00:00
Chayim Refael Friedman
4c2aa73df8
Merge pull request #21175 from A4-Tacks/indent-toggle-ignore
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Fix indent for toggle_ignore
2025-12-11 01:06:31 +00:00
Chayim Refael Friedman
cc0e07901a
Merge pull request #21187 from nicolas-guichard/push-orysqtulnxww
Include operator overload occurrences in SCIP index
2025-12-11 01:04:46 +00:00
Chayim Refael Friedman
fface27171
Merge pull request #21244 from ChayimFriedman2/deprecated-safe
fix: `#[rustc_deprecated_safe_2024]` can also come as `#[rustc_deprecated_safe_2024(audit_that = "reason")]`
2025-12-10 20:55:35 +00:00
Chayim Refael Friedman
fc265a27da #[rustc_deprecated_safe_2024] can also come as #[rustc_deprecated_safe_2024(audit_that = "reason")] 2025-12-10 22:45:20 +02:00
Chayim Refael Friedman
425f385a1c Support #[feature(associated_type_defaults)] 2025-12-10 22:27:21 +02:00
Chayim Refael Friedman
71b3bca7a1 Support the new lowering of format_args!() 2025-12-10 19:20:48 +02:00
Chayim Refael Friedman
6ff9f64f41
Merge pull request #21241 from ShoyuVanilla/issue-20487-again
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
fix: Support dyn compatibility for old toolchains without `MetaSized`
2025-12-10 15:52:40 +00:00
Shoyu Vanilla
b4ad7daf1b Bring back MINIMUM_SUPPORTED_TOOLCHAIN_VERSION to 1.78.0 2025-12-11 00:36:28 +09:00
Shoyu Vanilla
1f4229fd8d fix: Support dyn compatibility for old toolchains without MetaSized 2025-12-11 00:35:48 +09:00
Chayim Refael Friedman
2e9b59900d Move format_args!() lowering to a separate file
It's growing out of control.
2025-12-10 15:23:07 +02:00
A4-Tacks
d20efdc4c5
Fix assist and -> and_then parameter
- And fix fallback parentheses

Example
---
```rust
fn foo() {
    let foo = Some("foo");
    return foo.and$0(Some("bar"));
}
```

**Before this PR**

```rust
fn foo() {
    let foo = Some("foo");
    return foo.and_then(|| Some("bar"));
}
```

**After this PR**

```rust
fn foo() {
    let foo = Some("foo");
    return foo.and_then(|it| Some("bar"));
}
```

---

```rust
struct Func { f: fn() -> i32 }
fn foo() {
    let foo = true;
    let func = Func { f: || 2 };
    let x = foo.then$0(func.f);
}
```

**Before this PR**

```text
request handler panicked: Failed to make ast node `syntax::ast::generated::nodes::CallExpr` from text const C: () = func.f();
```

**After this PR**

```rust
struct Func { f: fn() -> i32 }
fn foo() {
    let foo = true;
    let func = Func { f: || 2 };
    let x = foo.then_some((func.f)());
}
```
2025-12-10 18:42:33 +08:00
Lukas Wirth
186e3fe017
Merge pull request #21233 from Veykril/push-ursspxxkozkk
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Revert "Turn `BlockLoc` into a tracked struct"
2025-12-10 07:52:40 +00:00
Lukas Wirth
0f26f674e9 Revert "Turn BlockLoc into a tracked struct"
This reverts commit 64cabd87be.
2025-12-10 08:43:07 +01:00
Chayim Refael Friedman
46a984ffa5
Merge pull request #21238 from Colepng/is_transmutable-fix
fix: is_transmutable always panicking
2025-12-10 07:31:12 +00:00
Cole Kauder-McMurrich
48fa324da2 fix: is_transmutable always panicking 2025-12-10 02:14:43 -05:00
Chayim Refael Friedman
7d052bdfe0
Merge pull request #21235 from benodiwal/fix-const-generic-param-env-panic
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
fix: resolve const generic param-env panic in type projection
2025-12-09 16:18:15 +00:00
benodiwal
d6271ab421
fix: resolve const generic param-env panic in type projection 2025-12-09 21:25:26 +05:30
Shoyu Vanilla (Flint)
e8ac25242f
Merge pull request #21044 from A4-Tacks/fix-make-unnamed-param
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Fix make::unnamed_param result a untyped_param
2025-12-09 04:45:26 +00:00
A4-Tacks
842f9650bc
Add complex tests for assist generate_fn_type_alias 2025-12-09 12:34:35 +08:00
Shoyu Vanilla (Flint)
5375f11482
Merge pull request #21210 from A4-Tacks/comp-unescaped-brace-fmt-str
Fix not complete `format!("{{{$0")` and underscore
2025-12-09 04:26:01 +00:00
Chayim Refael Friedman
e1b11fe83e
Merge pull request #21226 from benodiwal/fix/impl-display-trait-generic-args
Some checks are pending
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
fix: fixed Impl display to show trait generic args
2025-12-08 21:26:46 +00:00
Laurențiu Nicola
205a17262c
Merge pull request #21231 from Urgau/patch-2
Remove `[no-mentions]` handler in our triagebot config
2025-12-08 18:48:29 +00:00
Urgau
e5ee77537b
Remove [no-mentions] handler in our triagebot config
https://github.blog/changelog/2025-11-07-removing-notifications-for-mentions-in-commit-messages/
2025-12-08 19:19:22 +01:00
Shoyu Vanilla (Flint)
25278ada1a
Merge pull request #21209 from ChayimFriedman2/stale-expr
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
internal: Do not create stale expressions in body lowering
2025-12-08 16:28:46 +00:00
Shoyu Vanilla (Flint)
35d2fc42ea
Merge pull request #21207 from rust-lang/dependabot/npm_and_yarn/editors/code/multi-d0f6e8601e
Bump jws in /editors/code
2025-12-08 16:18:41 +00:00
Shoyu Vanilla (Flint)
a50c1ccc9c
Merge pull request #21221 from A4-Tacks/no-pub-in-variant-field
Some checks are pending
metrics / build_metrics (push) Waiting to run
metrics / other_metrics (diesel-1.4.8) (push) Blocked by required conditions
metrics / other_metrics (hyper-0.14.18) (push) Blocked by required conditions
metrics / other_metrics (ripgrep-13.0.0) (push) Blocked by required conditions
metrics / other_metrics (self) (push) Blocked by required conditions
metrics / other_metrics (webrender-2022) (push) Blocked by required conditions
metrics / generate_final_metrics (push) Blocked by required conditions
rustdoc / rustdoc (push) Waiting to run
Fix pub in enum variant field for no_such_field
2025-12-08 07:18:53 +00:00
Shoyu Vanilla (Flint)
a071c5cb04
Merge pull request #21174 from Young-Flash/migrate_convert_iter_for_each_to_for
internal: migrate `convert_iter_for_each_to_for` to SyntaxEditor api
2025-12-08 07:11:26 +00:00
Shoyu Vanilla (Flint)
3dfe74e02d
Merge pull request #21199 from Young-Flash/migrate_generate_delegate_trait
internal: migrate `generate_delegate_trait` to SyntaxEditor api
2025-12-08 07:10:19 +00:00