Commit Graph

16091 Commits

Author SHA1 Message Date
Jonas Schievink
0a8274dd46 Include remaining memory in memory usage stats 2021-04-01 23:01:07 +02:00
bors[bot]
25201b2dad
Merge #8274
8274: Adding a few more gifs and screenshots for features in manual r=Veykril a=MozarellaMan

Related  #8267,#6539. Gifs are [here](https://github.com/rust-analyzer/rust-analyzer/issues/6539#issuecomment-809574840)

Finishing up the last PR,  for the last two features that didn't have a visual example. 

For syntax highlighting, I wasn't able to find a theme that displayed the difference between an enum and struct, but I only tried a few apart from the default so there could be one out there! 

e.g., with the default light theme, `Ord` and `Ordering` in `use std::cmp::{Ord, Ordering}` had the same highlight colour. So I just went with displaying `mut` items being underlined.


Co-authored-by: Ayomide Bamidele <48062697+MozarellaMan@users.noreply.github.com>
2021-04-01 00:01:40 +00:00
bors[bot]
3dbd8b5e7c
Merge #8276
8276: Fix block inner item defined in macro r=jonas-schievink a=edwin0cheng

Fixes  #8229

r? @jonas-schievink 

Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
2021-03-31 19:56:01 +00:00
Edwin Cheng
6a3f2ce76c Fix block inner item defined in macro 2021-04-01 03:45:21 +08:00
Ayomide Bamidele
7bea1d8bfe Additional syntax highlighting screenshot in manual 2021-03-31 18:45:15 +01:00
Ayomide Bamidele
4296cc3318 Gif of "let = " typing assist 2021-03-31 16:39:04 +01:00
Ayomide Bamidele
d82176c146 Gifs and screenshots for features in manual (syntax highlighting and typing) 2021-03-31 16:20:54 +01:00
bors[bot]
75011bbccb
Merge #8210
8210: Implement "Extract type alias" assist r=jonas-schievink a=jonas-schievink



Co-authored-by: Jonas Schievink <jonas.schievink@ferrous-systems.com>
Co-authored-by: Jonas Schievink <jonasschievink@gmail.com>
2021-03-31 12:26:57 +00:00
bors[bot]
aca9004c7e
Merge #8271
8271: Fix fail to parse u128  in proc-macro r=edwin0cheng a=edwin0cheng

fixes #8270

bors r+

Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
2021-03-31 12:08:12 +00:00
Edwin Cheng
55a3364e35 Fix parse u128 bug in proc-macro 2021-03-31 19:50:36 +08:00
bors[bot]
b6e21a4ca4
Merge #8269
8269: internal: document semantics for missing names r=flodiebold a=matklad



Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-31 10:30:45 +00:00
Aleksey Kladov
5c0c09c9c3 internal: document semantics for missing names 2021-03-31 13:24:08 +03:00
bors[bot]
55d7d71590
Merge #8267
8267: Adding gifs and screenshots for features in manual r=matklad a=MozarellaMan

For #6539

This includes most of gif or screenshot examples of most items in the "Features" header. With the exceptions of:

- **On Typing Assists** - couldn't get it to work for a demo, I'm probably missing something?
- **Structural search and replace** - looked to be already a visual example of the feature
- **Workspace symbol** - wasn't sure how best to show this, all of the examples maybe? Also wasn't sure of the best code example to show it off
- **Semantic Syntax Highlighting** - seemed obvious enough to not need a screenshot, but I could easily add this

All the gifs/pngs are hosted in this [comment](https://github.com/rust-analyzer/rust-analyzer/issues/6539#issuecomment-809574840). Please let me know if any of them aren't suitable (and why) and I'll improve it! Or if you don't like the theme/font

Co-authored-by: Ayomide Bamidele <48062697+MozarellaMan@users.noreply.github.com>
2021-03-31 10:01:56 +00:00
bors[bot]
c69f6f31d1
Merge #8266
8266: Fix generic arguments being incorrectly offset in qualified trait casts r=flodiebold a=Veykril

We reverse the segments and generic args of the lowered path after building it, this wasn't accounted for when inserting the self parameter in `Type as Trait` segments.

Fixes #5886

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-03-31 09:52:47 +00:00
Ayomide Bamidele
276022682b Gifs and screenshots for features in manual 2021-03-31 00:08:10 +01:00
Lukas Wirth
6f0575f08a Fix generic arguments being incorrectly offset in qualified trait casts 2021-03-30 23:23:00 +02:00
bors[bot]
2436621b6c
Merge #8240
8240: 8024: Added the trait modifier for methods r=Veykril a=chetankhilosiya

method in impls and method calls will have trait modifier.

Trait modifier for constants is remaining.

Co-authored-by: Chetan Khilosiya <chetan.khilosiya@gmail.com>
2021-03-30 20:27:28 +00:00
Chetan Khilosiya
518c9c7548 Revert "8024: Added test case for highlighting trait items."
This reverts commit d7dcd41801.
2021-03-31 01:46:01 +05:30
Chetan Khilosiya
d0fcd5c5e0 8024: Fix for function name change. 2021-03-31 00:47:37 +05:30
Chetan Khilosiya
d7dcd41801 8024: Added test case for highlighting trait items. 2021-03-31 00:31:15 +05:30
Chetan Khilosiya
56f624532a 8024: Updated the implementation for trait modifier.
Fixed the test cases.
2021-03-31 00:31:15 +05:30
Chetan Khilosiya
f269fe7156 8024: Added the trait modifier for methods
method in impls and method calls will have trait modifier.
2021-03-31 00:31:15 +05:30
bors[bot]
fd7c454d51
Merge #8186
8186: Lower traits to `TraitRef` instead of `TypeRef` r=matklad a=Veykril



Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-03-30 16:45:05 +00:00
bors[bot]
277db63a08
Merge #8261
8261: Fix expansion of OR-patterns in match check r=Veykril a=Jesse-Bakker

Fixes #8249


Co-authored-by: Jesse Bakker <github@jessebakker.com>
2021-03-30 16:34:53 +00:00
bors[bot]
ab4fae45ac
Merge #8262
8262: internal: revive google_cpu_profile infra r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-30 14:32:04 +00:00
Aleksey Kladov
fb00b92dde internal: revive google_cpu_profile infra 2021-03-30 17:29:43 +03:00
Jesse Bakker
80fe03877d Fix expansion of OR-patterns in match check 2021-03-30 15:01:47 +02:00
bors[bot]
0b68e03bf5
Merge #8256
8256: Item movers improvements r=ivan770 a=ivan770

Closes #8236

Co-authored-by: ivan770 <leshenko.ivan770@gmail.com>
2021-03-30 11:10:20 +00:00
ivan770
4fcba8b1bf
Fix code style 2021-03-30 12:58:41 +02:00
Aleksey Kladov
8447ecf747 internal: switch from CLI to internal benchmarking
We have a CLI for benchmarking, but no one actually uses it it seems.
Let's try switching to "internal" benchmarks, implemented as rust tests.
They should be easier to "script" to automate tracking of perf
regressions.
2021-03-30 13:52:25 +03:00
ivan770
6ef6e4dee1
Improved node lookup algorithm, added more movable nodes 2021-03-30 12:44:09 +02:00
bors[bot]
563464bfae
Merge #8255
8255: internal: touch up dev readme r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-30 10:31:12 +00:00
Aleksey Kladov
ff8142d47e internal: touch up dev readme 2021-03-30 13:30:38 +03:00
bors[bot]
2490ab7718
Merge #8254
8254: internal: switch from CLI to internal benchmarking r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-30 09:47:49 +00:00
Aleksey Kladov
797185e1b6 internal: switch from CLI to internal benchmarking
We have a CLI for benchmarking, but no one actually uses it it seems.
Let's try switching to "internal" benchmarks, implemented as rust tests.
They should be easier to "script" to automate tracking of perf
regressions.
2021-03-30 12:47:23 +03:00
bors[bot]
904bdff224
Merge #8250
8250: More accurately classify assoc. types in paths r=jonas-schievink a=jonas-schievink

Previously `Iterator<Whoops$0 = ()>` would go to the `Iterator` trait. This fixes that and correctly marks `Whoops` as unresolved.

bors r+

Co-authored-by: Jonas Schievink <jonasschievink@gmail.com>
2021-03-30 00:10:30 +00:00
Jonas Schievink
41c7448e12 Accurately classify assoc. types in paths 2021-03-30 02:09:17 +02:00
bors[bot]
b3ca06e4fd
Merge #8247
8247: internal: ensure that runaway type-inference doesn't block the main loop r=flodiebold a=matklad

We have a bug where type-checking `per_query_memory_usage` takes a
couple of seconds. It also reveals another bug: our type inference is
not cancellable.

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-29 20:39:36 +00:00
bors[bot]
9bae3ecdff
Merge #8246
8246: update vim ycm installation instruction r=Veykril a=PSeitz

Fixes https://github.com/rust-analyzer/rust-analyzer.github.io/pull/97

Co-authored-by: PSeitz <PSeitz@users.noreply.github.com>
2021-03-29 20:18:51 +00:00
Aleksey Kladov
b35312d4af internal: ensure that runaway type-inference doesn't block the main loop
We have a bug where type-checking `per_query_memory_usage` takes a
couple of seconds. It also reveals another bug: our type inference is
not cancellable.
2021-03-29 23:15:12 +03:00
PSeitz
14a1f0ce46
remove enumeration 2021-03-29 22:09:04 +02:00
PSeitz
3153a80261
update vim ycm installation instruction 2021-03-29 21:31:29 +02:00
bors[bot]
35efbf5661
Merge #8244
8244: internal: track missing `.check_cancelled` r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-29 19:22:11 +00:00
Aleksey Kladov
483a5bc9c8 internal: track missing .check_cancelled 2021-03-29 21:38:23 +03:00
bors[bot]
7b9e2a2641
Merge #8243
8243: Remove code duplication in highlight injection r=Veykril a=Veykril

bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-03-29 18:18:40 +00:00
Lukas Wirth
6b8358d4d9 Remove code duplication in highlight injection 2021-03-29 20:11:28 +02:00
bors[bot]
95107a7ccf
Merge #8241
8241: internal: cleanup hprof r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-03-29 17:54:57 +00:00
Aleksey Kladov
2381a54c2f internal: cleanup hprof 2021-03-29 20:54:15 +03:00
Lukas Wirth
b4bb774381 Remove TraitRef::Error 2021-03-29 18:41:21 +02:00
Lukas Wirth
c2a63b97a8 Rename target_ty to self_ty 2021-03-29 17:47:47 +02:00