Daiki Ihara
873aa904f2
Fix var name
2021-06-21 22:47:39 +09:00
Daiki Ihara
7a04f72220
Fix pointed out
2021-06-21 18:42:25 +09:00
Daiki Ihara
cd1ef8de18
Fix extract_function with await
2021-06-21 18:31:53 +09:00
Florian Diebold
a1120b6879
Fix benchmark_include_macro
2021-06-20 19:37:45 +02:00
Florian Diebold
78419779f1
More cleanups, use check
for display_source_code
tests
2021-06-20 19:12:06 +02:00
Florian Diebold
0219b145ea
Clean up coercion tests
2021-06-20 19:12:06 +02:00
Florian Diebold
d340f28a81
test_utils: Make overlapping annotations possible
2021-06-20 19:12:06 +02:00
Florian Diebold
04fbdce426
Unify check_mismatches and check_types
2021-06-20 19:12:06 +02:00
Florian Diebold
679bb21633
Add coverage mark for block local impls
2021-06-20 19:12:06 +02:00
Aleksey Kladov
9a3eae8755
fix: don't add duplicate &
during completion
2021-06-20 19:37:58 +03:00
bors[bot]
f1097c2d26
Merge #9344
...
9344: fix: rename works when invoked on a reference r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-06-20 14:08:19 +00:00
Aleksey Kladov
cbb1979c19
fix: rename works when invoked on a reference
2021-06-20 17:07:55 +03:00
bors[bot]
3843bd02a0
Merge #9328
...
9328: internal: Update deps r=lnicola a=kjeremy
Co-authored-by: kjeremy <kjeremy@gmail.com>
2021-06-20 03:22:13 +00:00
Lukas Wirth
2113c46797
Cleanup insert_use tests
2021-06-19 22:33:29 +02:00
bors[bot]
c2aa7782d6
Merge #9338
...
9338: minor: use minicore r=matklad a=matklad
bors r+
🤖
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-06-19 09:18:34 +00:00
Aleksey Kladov
7df6852b6e
minor: use minicore
2021-06-19 12:03:59 +03: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
Aleksey Kladov
3762cc7465
minor: use minicore
2021-06-18 23:59:47 +03:00
Aleksey Kladov
90da9fc9b3
minor: use minicore
2021-06-18 23:48:18 +03:00
Aleksey Kladov
a9623f3165
minor: use minicore
2021-06-18 23:38:19 +03:00
Aleksey Kladov
cc73abf72c
minor: use minicore
2021-06-18 23:33:01 +03:00
Aleksey Kladov
181184a350
minor: use minicore
2021-06-18 23:28:37 +03:00
Aleksey Kladov
89a0e58393
internal: use minicore deref more
2021-06-18 22:47:02 +03:00
Aleksey Kladov
991919e71f
internal: add index to minicore
2021-06-18 22:37:34 +03:00
Aleksey Kladov
73b3ee664e
minor: use minicore
2021-06-18 22:25:35 +03:00
Aleksey Kladov
2e4df27132
minor: use minicore
2021-06-18 22:25:35 +03:00
Aleksey Kladov
15c4b3fa7f
internal: add Copy to minicore
2021-06-18 22:10:52 +03:00
kjeremy
e0e694620c
Update test
2021-06-18 14:36:12 -04:00
bors[bot]
0657812bc2
Merge #9321
...
9321: Inline generics in const and function trait completions r=Veykril a=RDambrosio016
This PR does a couple of things:
- moves path_transform from ide_assists to ide_db to be shared by both assists and completions
- when completing a const or a function for a trait, it will "inline" any generics in those associated items instead
of leaving the generic's name. For example:
```rust
trait Foo<T> {
const BAR: T;
fn foo() -> T;
}
struct Bar;
impl Foo<u32> for Bar {
// autocompletes to this
fn foo() -> u32;
// and not this (old)
fn foo() -> T;
// also works for associated consts and where clauses
const BAR: u32 = /* */
}
```
Currently this does not work for const generics, because `PathTransform` does not seem to account for them. If this should work on const generics too, `PathTransform` will need to be changed. However, it is uncommon to implement a trait only for a single const value, so this isnt a huge concern.
Co-authored-by: rdambrosio <rdambrosio016@gmail.com>
2021-06-18 16:47:58 +00:00
rdambrosio
b3e5c648e0
Lift ast -> hir out of the for_each
2021-06-18 12:42:13 -04:00
Laurențiu Nicola
6b1f0057f2
Avoid string allocation
2021-06-18 14:46:18 +03:00
Laurențiu Nicola
e3ce88f6f2
Minor clippy perf fixes
2021-06-18 14:40:51 +03:00
rdambrosio
23e3354ae0
Remove extra whitespace
2021-06-18 02:14:00 -04:00
rdambrosio
8e08b86304
Feat: inline generics in const and func trait completions
2021-06-17 19:54:28 -04:00
bors[bot]
0d863ccea9
Merge #9313
...
9313: fix: Don't complete keywords in attributes inside expressions r=Veykril a=Veykril
bors r+
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-06-17 22:30:30 +00: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
89c2dff58a
minor: simplify
2021-06-18 00:36:25 +03:00
Aleksey Kladov
ebb591a570
internal: add derive and ord support to minicore
2021-06-18 00:30:22 +03:00
Lukas Wirth
c1bf1f88ad
Complete repr
attribute parameters
2021-06-17 21:15:49 +02: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
bors[bot]
ce926aebc4
Merge #9315
...
9315: Nest all the or-patterns! r=Veykril a=Veykril
`cargo +nightly clippy --fix -Z unstable-options --allow-dirty -- -A clippy::all -D clippy::unnested_or_patterns`
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-06-17 16:22:32 +00:00
Lukas Wirth
02d25ab60d
Fix parser tests for 1.53
2021-06-17 18:09:44 +02:00
Lukas Wirth
b6cb6d5abe
simplify
2021-06-17 17:58:26 +02:00
Lukas Wirth
95c8c65139
Nest all the or-patterns!
2021-06-17 17:37:14 +02:00
Lukas Wirth
2ac03ef1d6
Don't complete keywords in attributes inside expressions
2021-06-17 16:02:51 +02:00
Lukas Wirth
2a48b53220
Correct completions in items tests
2021-06-17 15:43:21 +02:00