Lukas Wirth
c41f1279a3
Inline name classification reference calls
2021-07-11 15:39:09 +02:00
Lukas Wirth
c65bb7f8b9
Explicitly check for reference locals or fields in Name classification
2021-07-11 15:04:40 +02:00
bors[bot]
87621de2b9
Merge #9567 #9568
...
9567: remove unneded special case r=matklad a=matklad
bors r+
🤖
9568: feat: add 'for' postfix completion r=lnicola a=mahdi-frms
![Peek 2021-07-11 16-45](https://user-images.githubusercontent.com/62165556/125194692-a0aaf780-e267-11eb-952a-81de7955d9a1.gif )
adds #9561
used ```ele``` as identifier for each element in the iteration
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Co-authored-by: mahdi-frms <mahdif1380@outlook.com>
2021-07-11 12:51:33 +00:00
Aleksey Kladov
bbb053532e
internal: remove one more needless extern crate
2021-07-11 15:48:49 +03:00
mahdi-frms
7bae9c9187
add 'for' postfix completion
2021-07-11 17:10:57 +04:30
Aleksey Kladov
dbf11b16da
typo
2021-07-11 15:13:42 +03:00
Aleksey Kladov
1171dc74e0
internal: remove unused param
2021-07-11 15:08:00 +03:00
Aleksey Kladov
f42648e305
internal: remove needless distinction between a carte and its root mod
2021-07-11 14:55:24 +03:00
Aleksey Kladov
dedf0ff7c5
internal: document NameClass and NameRefClass
2021-07-11 14:41:21 +03:00
Lukas Wirth
79614c486b
Enable auto_import
on ident patterns
2021-07-10 17:57:33 +02:00
Lukas Wirth
dafbe6940e
Wrap inlined closures in parens when inlined in an expression in inline_call
2021-07-05 15:42:11 +02:00
Aleksey Kladov
86720f2953
minor: drop dummy authors field
2021-07-05 14:19:41 +03:00
Lukas Wirth
e41b5348b8
replace_qualified_name_with_use
insert qualified import paths
2021-07-03 23:42:59 +02:00
bors[bot]
336194c09b
Merge #9476
...
9476: internal: overhaul codegen r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-07-03 19:26:04 +00:00
Aleksey Kladov
660930623e
feat: regenrate lint completions
2021-07-03 22:24:36 +03:00
Lukas Wirth
688398febc
feat: Implement inline_method
assist
2021-07-03 01:33:34 +02:00
Lukas Wirth
26dd0c4e5b
wrap_return_type_in_result works on the HIR
2021-07-02 23:19:32 +02:00
Lukas Wirth
a7d61ddba4
Add cov_mark
2021-07-02 19:34:49 +02:00
Lukas Wirth
f640f2dbb4
Fix incorrect guard for NameRefClass attribute resolution
2021-07-02 15:17:21 +02:00
bors[bot]
564fa0146e
Merge #9450
...
9450: internal: Add ModuleOrItem guess to import granularity guessing r=Veykril a=Veykril
I think this should be the last fix needed for this(🤞 )
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-07-01 19:33:53 +00:00
Lukas Wirth
7c8ef301ca
Add ModuleOrItem guess to import granularity guessing
2021-07-01 21:32:35 +02:00
Lukas Wirth
04f1104179
Don't classify NameRef paths inside attribute TokenTrees
2021-06-30 21:51:28 +02:00
Lukas Wirth
9957220dfe
Fix NameRef::classify
path resolution inside attributes
2021-06-28 19:07:23 +02:00
Lukas Wirth
34c28c1bbc
Include self
in usage search for modules in their definition source
2021-06-28 16:41:35 +02:00
Lukas Wirth
3ce5c66ca1
Deduplicate ast expression walking logic
2021-06-27 01:11:57 +02:00
bors[bot]
2ac1ffc0f3
Merge #9400
...
9400: fix: Fix renaming associated trait items with colliding names r=Veykril a=Veykril
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-06-25 01:48:50 +00:00
Lukas Wirth
942eeb2f55
Fix renaming associated trait items with colliding names
2021-06-25 03:45:41 +02:00
Aleksey Kladov
7be2d2f008
internal: remove one more accidentally quadratic code-path
...
Definition::visibility was implemented in a rather roundabout way -- by
asking the parent module about the effective visibility.
This is problematic for a couple of reasons:
* first, it doesn't work for local items
* second, asking module about visibility of a child is a linear
operation (that's a problem in itself, tracked in #9378 )
Instead, lets ask the declared visibility directly, we have all the code
for it, and need only to actually us it.
2021-06-22 21:26:07 +03:00
Lukas Wirth
f615efdfc3
Factor out pick_best_token
ide pattern into ide_db
2021-06-22 17:50:15 +02:00
Lukas Wirth
2113c46797
Cleanup insert_use tests
2021-06-19 22:33:29 +02:00
Lukas Wirth
344cb5e76a
Don't insert imports outside of cfg attributed items
2021-06-18 23:56:43 +02:00
bors[bot]
d9666ce509
Merge #9334
...
9334: feat: Allow to disable import insertion on single path glob imports r=Veykril a=Veykril
On by default as I feel like this is something the majority would prefer.
Closes #8490
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-06-18 21:23:22 +00:00
Lukas Wirth
2ee090faaf
Allow to disable import insertion on single path glob imports
2021-06-18 23:11:56 +02:00
rdambrosio
8e08b86304
Feat: inline generics in const and func trait completions
2021-06-17 19:54:28 -04:00
Aleksey Kladov
66673eae2b
internal: retire famous_defs_fixture
...
This is now done declaratively via `minicore`.
2021-06-18 00:42:32 +03:00
Aleksey Kladov
ebb591a570
internal: add derive and ord support to minicore
2021-06-18 00:30:22 +03:00
Aleksey Kladov
ca99aaa053
internal: add From to minicore
2021-06-17 21:04:12 +03:00
Aleksey Kladov
82c7afc703
minor: dead code
2021-06-17 20:51:34 +03:00
Aleksey Kladov
08c220ab2c
internal: add default to minicore
2021-06-17 20:49:49 +03:00
Aleksey Kladov
ac35645455
internal: remove dead code
2021-06-17 11:42:43 +03:00
Aleksey Kladov
a43bba760e
internal: switch some tests to minicore
2021-06-17 11:41:36 +03:00
Aleksey Kladov
1e100e8b3e
internal: cleanup tests
...
* ensure standard, non-indented style (should add this check to
`fixture` some day)
* removed a couple of ignores
2021-06-15 12:48:05 +03:00
Aleksey Kladov
c2015e7d18
internal: more natural order of sources for TypeParam
...
We usually use first (left) variant of `Either` for "usual" case, and
use right for odd things. For example, pat source is Pat | SelfParam.
2021-06-14 22:42:43 +03:00
Aleksey Kladov
94f7b63522
minor: less ambiguous name
2021-06-14 19:16:03 +03:00
Aleksey Kladov
9fb67e7477
internal: document rename challenges
2021-06-14 19:08:12 +03:00
Aleksey Kladov
26c978f258
internal: adapt diagnostics to the new rename API
2021-06-14 18:46:54 +03:00
Aleksey Kladov
a91071b57b
internal: cut deps between assists and diagnostics
2021-06-14 17:45:17 +03:00
Maan2003
5ac6804bb3
cargo fmt
2021-06-13 09:48:15 +05:30
Maan2003
c9b4ac5be4
clippy::redudant_borrow
2021-06-13 09:24:16 +05:30
Aleksey Kladov
0463d76a1f
internal: cross-crate cov-marks
2021-06-12 23:40:52 +03:00