bors
acafce3389
Auto merge of #16309 - Veykril:proc-macro-srv-err, r=Veykril
...
Recognize proc macro server unexpectedly exiting and report the exit code
2024-01-09 10:01:10 +00:00
bors
c246ecfd55
Auto merge of #16310 - Veykril:range-access-parse, r=Veykril
...
fix: Fix incorrect parsing error on method call on range
Fixes https://github.com/rust-lang/rust-analyzer/issues/16289
2024-01-09 09:49:25 +00:00
bors
25f71469f1
Auto merge of #16311 - Veykril:rustc-deps, r=Veykril
...
internal: Remove `rustc_dependencies ` crate
The crate serves no purpose really
2024-01-09 09:37:48 +00:00
Lukas Wirth
21a953fe37
Recognize proc macro server unexpectedly exiting and report the exit code
2024-01-09 10:37:26 +01:00
Lukas Wirth
a8c94eaf13
fix: Fix rust-analyzer-proc-macro-srv failing to spawn on windows
2024-01-09 10:35:54 +01:00
Lukas Wirth
e1c67485bf
fix: Differentiate between vfs config load and file changed events
2024-01-09 10:30:16 +01:00
Laurențiu Nicola
4413aeb9e8
Temporarily disable resolve_proc_macro test
2024-01-09 10:27:36 +02:00
Laurențiu Nicola
b0b2b1c5f1
Fix allow(dead_code)
2024-01-09 10:00:57 +02:00
Laurențiu Nicola
0ae73738ad
Try to fix feature gates
2024-01-09 09:52:58 +02:00
Laurențiu Nicola
f52f2f9c3c
Merge branch 'master' into sync-from-rust
2024-01-09 08:46:16 +02:00
bors
598511b4e8
Auto merge of #16308 - Veykril:builtin-macro-hygiene, r=lnicola
...
Builtin derives are hygienic
Closes https://github.com/rust-lang/rust-analyzer/issues/16295
2024-01-08 17:10:32 +00:00
dfireBird
df5c647982
add notable_trait predicate to CompletionRelevance
...
implement the predicate set on the case function from traits
2024-01-08 20:34:11 +05:30
Lukas Wirth
f972da70d4
Remove rustc_dependencies crate
2024-01-08 15:39:35 +01:00
Lukas Wirth
e25e0dd0ad
Split out rustc_parse_format from rustc_dependencies
2024-01-08 15:30:26 +01:00
Lukas Wirth
b97ab00bd4
Split out rustc_lexer from rustc_dependencies
2024-01-08 15:24:46 +01:00
Lukas Wirth
72200641c1
fix: Fix incorrect parsing error on method call on range
2024-01-08 15:09:26 +01:00
Lukas Wirth
1c40ac79c8
VFS no longer stores all source files in memory
2024-01-08 12:51:16 +01:00
Lukas Wirth
7dd9f20ce3
Builtin derives are hygienic
2024-01-08 12:50:11 +01:00
Laurențiu Nicola
3afeb24198
Merge commit 'af40101841c45aa75b56f4e9ca745369da8fb4ba' into sync-from-ra
2024-01-08 11:29:25 +02:00
bors
6ce3f44597
Auto merge of #16298 - riverbl:exclusive-range-hint, r=Veykril
...
feat: Add inlay hint for exclusive ranges
Adds an inlay hint containing a '<' character to exclusive range expressions and patterns that specify an upper bound.

Inspired by [this comment](https://github.com/rust-lang/rust/issues/37854#issuecomment-1865124907 ) noting that IntelliJ Rust has this feature.
2024-01-07 10:21:39 +00:00
riverbl
3c378b9c70
Add inlay hint for exclusive ranges
...
Adds an inlay hint containing a '<' character to exclusive range expressions and patterns that specify an upper bound.
2024-01-07 09:33:56 +00:00
Matthias Krüger
3fb2cd2002
autofix remaining perf findings
2024-01-07 01:20:20 +01:00
Matthias Krüger
196650dfaf
don't to_string() format args
2024-01-07 01:11:57 +01:00
Matthias Krüger
b22bd36f6e
remove more redundant clones manually
2024-01-07 00:26:49 +01:00
Matthias Krüger
476e10e961
remove redundant clones
2024-01-07 00:17:48 +01:00
bors
f595e60b6d
Auto merge of #16290 - Veykril:chalk, r=Veykril
...
internal: Reduce vec cloning in mir lowering/eval
2024-01-06 22:13:09 +00:00
bors
e9ae0b7ab4
Auto merge of #16285 - lnicola:repr-packed-unaligned, r=Veykril
...
fix: Fix panic on unaligned packed attribute
Closes #16284
2024-01-06 20:35:56 +00:00
Lukas Wirth
5ac0c14384
Remove some vec clones in const-eval
2024-01-06 21:33:47 +01:00
Laurențiu Nicola
d17156a774
Add some repr(packed) tests
2024-01-06 21:24:01 +02:00
bors
f8eab9b7d2
Auto merge of #16279 - Veykril:ide-tuple-fields, r=Veykril
...
feat: IDE features for primitive tuple fields
Fixes https://github.com/rust-lang/rust-analyzer/issues/13018
2024-01-06 18:30:10 +00:00
Laurențiu Nicola
30e17e377c
Fix panic on unaligned packed attribute
2024-01-06 19:54:57 +02:00
Lukas Wirth
5125063a21
Remove unnecessary cloning
2024-01-06 17:48:07 +01:00
Lukas Wirth
c9c4053eed
More aliases
2024-01-06 16:58:15 +01:00
Lukas Wirth
963568b46f
feat: IDE features for primitive tuple fields
2024-01-06 15:04:58 +01:00
roife
ba952e65ff
Transform paths before make::fn_
2024-01-06 20:09:51 +08:00
roife
872951d2d9
Replace 'postorder' with 'reverse of preorder' to traverse the AST in path_transform
2024-01-06 20:07:38 +08:00
davidsemakula
89d6b011c4
remove unnecessary ast::Path::segments alternatives
2024-01-06 12:53:56 +03:00
davidsemakula
6403dbf011
fix ast::Path::segments callers that implicitly relied on behavior of previous implementation
2024-01-06 12:52:33 +03:00
davidsemakula
08c44a6c24
fix ast::Path::segments implementation
2024-01-06 08:41:11 +03:00
bors
e53792b7cb
Auto merge of #16256 - Urhengulas:ide-runnables-assert_eq, r=Veykril
...
internal: Only compare relevant parts in `ide::{runnables,inlay_hints}` tests
This PR limits the data being compared. Therefore the tests should be more readable, as well as being more robust to changes to the data structure.
Part of https://github.com/rust-lang/rust-analyzer/issues/14268 .
2024-01-05 13:49:30 +00:00
bors
2271b82007
Auto merge of #16264 - roife:refactor/refactor-generate-delegate-trait, r=Veykril
...
internal: clean and enhance readability for `generate_delegate_trait`
Continue from #16112
This PR primarily involves some cleanup and simple refactoring work, including:
- Adding numerous comments to layer the code and explain the behavior of each step.
- Renaming some variables to make them more sensible.
- Simplify certain operations using a more elegant approach.
The goal is to make this intricate implementation clearer and facilitate future maintenance.
In addition to this, the PR also removes redundant `path_transform` operations for `type_gen_args`.
Taking the example of `impl Trait<T1> for S<S1>`, where `S1` is considered. The struct `S` must be in the file where the user triggers code actions, so there's no need for the `path_transform`. Furthermore, before performing the transform, we've already renamed `S1`, ensuring it won't clash with existing generics parameters. Therefore, there's no need to transform it.
2024-01-05 13:37:54 +00:00
bors
59457091bb
Auto merge of #16199 - Young-Flash:extract_struct_with_Self, r=Veykril
...
fix: `extract_struct_from_enum_variant` assist should resolve Self generic arg
close https://github.com/rust-lang/rust-analyzer/issues/16197
2024-01-05 13:26:34 +00:00
bors
2980d54160
Auto merge of #16223 - Young-Flash:quickfix_redundant_assoc_item, r=Veykril
...
feat: add quickfix for redundant_assoc_item diagnostic
Happy New Year 😊
follow up https://github.com/rust-lang/rust-analyzer/pull/15990 , now it's time to close https://github.com/rust-lang/rust-analyzer/issues/15958 , closes https://github.com/rust-lang/rust-analyzer/issues/16269

EDIT: add a demo.git would be more illustrated when making release change log.
2024-01-05 13:15:01 +00:00
bors
af102bab0e
Auto merge of #16270 - Veykril:flyimport-perf, r=Veykril
...
internal: Speed up import searching some more
Pushes the sorting to the caller, meaning additional filtering can be done pre-sorting. Similarly a collect call was pushed to the caller for allowing some other filters to run pre-collecting.
2024-01-05 12:03:02 +00:00
Lukas Wirth
cc2b79feeb
internal: Speed up import searching some more
2024-01-05 12:58:20 +01:00
bors
dc31cef5fc
Auto merge of #16268 - Veykril:method-trait-completion-limit, r=Veykril
...
Remove completion limit for trait importing method completions
Fixes https://github.com/rust-lang/rust-analyzer/issues/16075
The < 3 char limit never applied to methods and the amount of completions generated due this is not absolutely massive as not all traits in a project are ever applicable so there is little reason to employ the limit here. Especially as it limits the number of traits we consider, not items (after my changes yesterday), and the number of traits is not the slowing factor here. Tested this in r-a where we have ~800 traits project wide and even when ~260 are applicable there was no noticable slow down from it.
2024-01-05 11:14:37 +00:00
Lukas Wirth
4f75e0f910
Remove completion limit for trait importing method completions
2024-01-05 12:03:08 +01:00
bors
11b0126679
Auto merge of #16267 - Veykril:import-map-fix, r=Veykril
...
internal: Deduplicate some code
2024-01-05 10:43:52 +00:00
Lukas Wirth
d60638e5e6
Deduplicate some code
2024-01-05 11:34:18 +01:00
roife
fbdc59c54a
internal: remove unnecessary path_tranform on type_gen_args in generate_delegate_trait.
2024-01-05 13:59:44 +08:00