Commit Graph

27375 Commits

Author SHA1 Message Date
davidsemakula
d7a03022f7 handle divergence in child if expr for unnecessary else diagnostic fix 2024-02-06 19:00:10 +03:00
davidsemakula
62cc4f9c46 add unnecessary else diagnostic 2024-02-06 19:00:10 +03:00
bors
1974e7490d Auto merge of #16501 - lnicola:lete-snippet-docs, r=lnicola
minor: Add `lete` to postfix completion list
2024-02-06 11:15:27 +00:00
Laurențiu Nicola
2c4152847a Add lete to postfix completion list 2024-02-06 13:13:51 +02:00
bors
0dd62c0d59 Auto merge of #16500 - lnicola:clippy-windows, r=lnicola
internal: run Clippy on Windows

CC https://github.com/rust-lang/rust-analyzer/pull/16413#issuecomment-1927592897

![image](https://github.com/rust-lang/rust-analyzer/assets/308347/3bb4c06b-6388-4b1e-81f5-f0c2fbc3302c)
2024-02-06 10:08:45 +00:00
Laurențiu Nicola
32f0a2fc39 Run Clippy on Windows 2024-02-06 11:22:26 +02:00
bors
6671d3c9a3 Auto merge of #16499 - Nadrieril:update-pat-ana, r=lnicola
internal: Update rustc_pattern_analysis dependency

Just bumping the dependency, as I've been making API changes over on the rustc side. More API changes incoming in the coming weeks.

One benefit of this: we no longer abort in the `DeconstructedPat: Debug` impl, which means we can use `tracing` to investigate issues.
2024-02-06 07:04:33 +00:00
bors
64411a4ea3 Auto merge of #16496 - matthiaskrgr:c, r=lnicola
minor: remove clones
2024-02-06 06:47:13 +00:00
Nadrieril
d2d4119d24 Don't need an arena for types anymore 2024-02-06 05:09:30 +01:00
Nadrieril
ba7b12e062 Update rustc_pattern_analysis dependency 2024-02-06 05:08:19 +01:00
Nadrieril
c2d21242aa Tweak variant_id_for_adt 2024-02-06 05:01:05 +01:00
Matthias Krüger
ac9d1a03a7 remove clones 2024-02-05 23:15:47 +01:00
bors
66cec4d11a Auto merge of #16470 - Veykril:clippy-disallow, r=lnicola
internal: Lint debug prints and disallowed types with clippy
2024-02-05 17:20:43 +00:00
bors
cb37fcc616 Auto merge of #16493 - Young-Flash:method_call_parser, r=Veykril
fix: emit parser error for missing argument list

close https://github.com/rust-lang/rust-analyzer/issues/16362
2024-02-05 13:03:03 +00:00
Young-Flash
864c3d5880 test: add method_call_missing_argument_list error test 2024-02-05 17:54:09 +08:00
Young-Flash
c495e3f00f fix: emit parser error for missing argument list 2024-02-05 17:54:09 +08:00
bors
7fb639ffc1 Auto merge of #16482 - GnomedDev:boxed-subtree, r=lnicola
Swap Subtree::token_trees from Vec to boxed slice

Performs one of the optimizations suggested in #16325, but a little bit more. Boxed slices guarantee `shrink_to_fit` aswell as saving a pointer width as no capacity has to be stored.

Most of the diff is:
- Changing `vec![]` to `Box::new([])`
- Changing initialize -> fill into fill -> into_boxed_slice
- Working around the lack of an owned iterator or automatic iteration over a `Box<[T]>`

I would like to use my own crate, [small-fixed-array](https://lib.rs/small-fixed-array), although I understand if it isn't mature enough for this. If I'm given the go ahead, I can rework this PR to use it instead.
2024-02-05 09:14:06 +00:00
bors
3e47532dd4 Auto merge of #16474 - davidbarsky:david/import-on-the-fly-improvements, r=lnicola
internal: even more `tracing`

As part of profiling completions, I added some additional spans and moved `TyBuilder::subst_for_def` closer to its usage site (the latter had a small impact on completion performance. Thanks for the tip, Lukas!)
2024-02-05 09:01:58 +00:00
bors
081cf026b8 Auto merge of #16480 - GnomedDev:remove-unused-visit_ids, r=lnicola
Remove unused Subtree::visit_ids function

Completely unused, nothing else even shows up when searching for `visit_ids`.
2024-02-05 08:49:39 +00:00
bors
06737ec7ff Auto merge of #16492 - lnicola:sync-from-rust, r=lnicola
internal: Sync from downstream
2024-02-05 08:35:11 +00:00
Laurențiu Nicola
4efdb470e9 Merge branch 'master' into sync-from-rust 2024-02-05 10:33:31 +02:00
Laurențiu Nicola
ec3f7b5169 Merge commit '0113bc9388b480fa42c632f57f4f0f7af5813ec1' into sync-from-rust 2024-02-05 10:33:22 +02:00
GnomedDev
a607e1b04b
Use reserve_exact for pushing to Subtree 2024-02-04 22:17:20 +00:00
bors
39ad79bec5 Auto merge of #16485 - Young-Flash:minor, r=lnicola
minor: polish warning msg

sorry for this 😅

![PixPin_2024-02-04_18-33-23](https://github.com/rust-lang/rust-analyzer/assets/71162630/9aaa49d7-34f4-4c78-b91c-e85550252e25)
2024-02-04 19:36:00 +00:00
Young-Flash
bec1e0f616 minor: polish warning msg 2024-02-04 18:37:09 +08:00
Laurențiu Nicola
38b5c8c966 Try to fix in-tree build 2024-02-04 11:07:35 +02:00
Laurențiu Nicola
b8a3180a60 Merge commit '0113bc9388b480fa42c632f57f4f0f7af5813ec1' into sync-from-ra 2024-02-04 10:37:58 +02:00
GnomedDev
8011b56827
Swap Subtree::token_trees from Vec to boxed slice 2024-02-04 00:28:22 +00:00
bors
0113bc9388 Auto merge of #16479 - lnicola:macos-12, r=lnicola
internal: Bump release runners to MacOS 12
2024-02-03 17:27:05 +00:00
GnomedDev
1451270372
Remove unused Subtree::visit_ids function 2024-02-03 17:22:45 +00:00
Laurențiu Nicola
a605b9605e Bump release runners to MacOS 12 2024-02-03 19:16:32 +02:00
bors
8f6a72871e Auto merge of #16469 - Young-Flash:ci_typos, r=lnicola
internal: add typos check CI (part 2)

follow up https://github.com/rust-lang/rust-analyzer/pull/16448
2024-02-02 12:02:48 +00:00
Young-Flash
a52a4d9ba4 internal: update typo-check CI setting 2024-02-02 18:32:20 +08:00
Young-Flash
70d6141859 internal: update .typos.tmol 2024-02-02 18:23:11 +08:00
Young-Flash
ba2910a3a7 minor: correct some typos 2024-02-02 18:22:54 +08:00
bors
980d348111 Auto merge of #16476 - lnicola:sync-from-rust, r=lnicola
internal: sync from downstream
2024-02-02 07:07:05 +00:00
Laurențiu Nicola
7a0b887665 Bump rustc_index and rustc_abi 2024-02-02 09:00:21 +02:00
Laurențiu Nicola
ef07b05c0f Bump rustc_lexer and rustc_parse_format 2024-02-02 08:58:34 +02:00
Laurențiu Nicola
4f09335063 Merge remote-tracking branch 'upstream/master' into sync-from-rust 2024-02-02 08:40:28 +02:00
Laurențiu Nicola
8ba31cc4b9 Merge remote-tracking branch 'upstream/release' into sync-from-rust 2024-02-02 08:40:18 +02:00
David Barsky
f9bef39d48 internal: add some more tracing spans inside of hir-ty 2024-02-01 16:10:32 -05:00
David Barsky
0fd770613b internal: Move TyBuilder::subst_for_def into a block 2024-02-01 16:06:05 -05:00
Lukas Wirth
9e8a0fae0c Lint debug prints and disallowed types with clippy 2024-02-01 17:57:27 +01:00
bors
850ba2fb63 Auto merge of #16451 - Urhengulas:satisfy-clippy, r=Veykril
internal: Work through temporarily allowed clippy lints, part 2

Another follow-up to https://github.com/rust-lang/rust-analyzer/pull/16401.
2024-02-01 14:23:18 +00:00
Young-Flash
b0be2967cc internal: add typos CI check 2024-02-01 21:07:50 +08:00
Young-Flash
36cb518791 internal: add typos.toml as typo white list 2024-02-01 21:04:38 +08:00
bors
135a8d9841 Auto merge of #16416 - Young-Flash:cargo_ext_detect, r=lnicola
internal: VS Code: report conflict with `panicbit.cargo`

<img width="359" alt="notification" src="https://github.com/rust-lang/rust-analyzer/assets/71162630/420b9f34-ba73-4436-b868-6cd87c62287d">

related to https://github.com/rust-lang/rust-analyzer/issues/16392
2024-02-01 13:00:05 +00:00
bors
3afa6b13c2 Auto merge of #16468 - ThomasFrans:docs-update-plugin-url, r=lnicola
minor: Recommend maintained Neovim plugin in documentation
2024-02-01 10:19:51 +00:00
Thomas Frans
671c776d59
minor: Recommend maintained Neovim plugin in documentation 2024-02-01 11:06:34 +01:00
bors
42cb1a2bd7 Auto merge of #16465 - Veykril:eprintln, r=Veykril
minor: Remove `stdx::eprintln` overwrite
2024-01-31 21:07:50 +00:00