aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--editors/README.md25
1 files changed, 18 insertions, 7 deletions
diff --git a/editors/README.md b/editors/README.md
index 9ed65e631..b35a1f367 100644
--- a/editors/README.md
+++ b/editors/README.md
@@ -9,7 +9,7 @@ $ cargo install-code
9$ rustup component add rust-src 9$ rustup component add rust-src
10``` 10```
11 11
12This will run `cargo install --packge ra_lsp_server` to install the server 12This will run `cargo install --package ra_lsp_server` to install the server
13binary into `~/.cargo/bin`, and then will build and install plugin from 13binary into `~/.cargo/bin`, and then will build and install plugin from
14`editors/code`. See 14`editors/code`. See
15[this](https://github.com/rust-analyzer/rust-analyzer/blob/0199572a3d06ff66eeae85a2d2c9762996f0d2d8/crates/tools/src/main.rs#L150) 15[this](https://github.com/rust-analyzer/rust-analyzer/blob/0199572a3d06ff66eeae85a2d2c9762996f0d2d8/crates/tools/src/main.rs#L150)
@@ -18,9 +18,9 @@ bugs!
18 18
19It's better to remove existing Rust plugins to avoid interference. 19It's better to remove existing Rust plugins to avoid interference.
20 20
21## Rust Analyzer Specifc Features 21## Rust Analyzer Specific Features
22 22
23These features are implemented as extensions to the langauge server protocol. 23These features are implemented as extensions to the language server protocol.
24They are more experimental in nature and work only with VS Code. 24They are more experimental in nature and work only with VS Code.
25 25
26### Syntax highlighting 26### Syntax highlighting
@@ -36,7 +36,7 @@ symbols can be used to narrow down the search. Specifically,
36- `#Foo` searches for `Foo` type in the current workspace 36- `#Foo` searches for `Foo` type in the current workspace
37- `#foo#` searches for `foo` function in the current workspace 37- `#foo#` searches for `foo` function in the current workspace
38- `#Foo*` searches for `Foo` type among dependencies, excluding `stdlib` 38- `#Foo*` searches for `Foo` type among dependencies, excluding `stdlib`
39- `#foo#*` seaches for `foo` function among dependencies. 39- `#foo#*` searches for `foo` function among dependencies.
40 40
41That is, `#` switches from "types" to all symbols, `*` switches from the current 41That is, `#` switches from "types" to all symbols, `*` switches from the current
42workspace to dependencies. 42workspace to dependencies.
@@ -87,7 +87,7 @@ Some features trigger on typing certain characters:
87 87
88### Code Actions (Assists) 88### Code Actions (Assists)
89 89
90These are triggered in a particular context via lightbulb. We use custom code on 90These are triggered in a particular context via light bulb. We use custom code on
91the VS Code side to be able to position cursor. 91the VS Code side to be able to position cursor.
92 92
93 93
@@ -196,7 +196,8 @@ use algo::{<|>visitor::{Visitor, visit}};
196 falls back to heuristic name matching for other things for the time being. 196 falls back to heuristic name matching for other things for the time being.
197 197
198* **Completion**: completes paths, including dependencies and standard library. 198* **Completion**: completes paths, including dependencies and standard library.
199 Does not handle glob imports and macros. Completes fields and inherent methods 199 Does not handle glob imports and macros. Completes fields and inherent
200 methods.
200 201
201* **Outline** <kbd>alt+shift+o</kbd> 202* **Outline** <kbd>alt+shift+o</kbd>
202 203
@@ -216,4 +217,14 @@ use algo::{<|>visitor::{Visitor, visit}};
216* **Diagnostics** 217* **Diagnostics**
217 - missing module for `mod foo;` with a fix to create `foo.rs`. 218 - missing module for `mod foo;` with a fix to create `foo.rs`.
218 - struct field shorthand 219 - struct field shorthand
219 - unnessary braces in use item 220 - unnecessary braces in use item
221
222
223## Performance
224
225Rust Analyzer is expected to be pretty fast. Specifically, the initial analysis
226of the project (i.e, when you first invoke completion or symbols) typically
227takes dozen of seconds at most. After that, everything is supposed to be more or
228less instant. However currently all analysis results are kept in memory, so
229memory usage is pretty high. Working with `rust-lang/rust` repo, for example,
230needs about 5 gigabytes of ram.