diff options
Diffstat (limited to 'docs/user')
-rw-r--r-- | docs/user/manual.adoc | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/docs/user/manual.adoc b/docs/user/manual.adoc index f4c37353c..8656dd1da 100644 --- a/docs/user/manual.adoc +++ b/docs/user/manual.adoc | |||
@@ -384,11 +384,9 @@ If the LSP binary is not available, GNOME Builder can install it when opening a | |||
384 | 384 | ||
385 | === Eclipse IDE | 385 | === Eclipse IDE |
386 | 386 | ||
387 | Prerequisites: You have installed the <<rust-analyzer-language-server-binary,`rust-analyzer` binary>>. | ||
388 | |||
389 | Support for Rust development in the Eclipse IDE is provided by link:https://github.com/eclipse/corrosion[Eclipse Corrosion]. | 387 | Support for Rust development in the Eclipse IDE is provided by link:https://github.com/eclipse/corrosion[Eclipse Corrosion]. |
390 | While it currently uses RLS as default, you can successfully configure it so the IDE will use `rust-analyzer` instead. | 388 | If available in PATH or in some standard location, `rust-analyzer` is detected and powers editing of Rust files without further configuration. |
391 | To do so, with an Eclipse IDE where Corrosion is installed, just go to __Window > Preferences > Rust__ and edit the __Path to Rust Language Server__ entry to reference the path to `rust-analyzer`. | 389 | If `rust-analyzer` is not detected, Corrosion will prompt you for configuration of your Rust toolchain and language server with a link to the __Window > Preferences > Rust__ preference page; from here a button allows to download and configure `rust-analyzer`, but you can also reference another installation. |
392 | You'll need to close and reopen all .rs and Cargo files, or to restart the IDE, for this change to take effect. | 390 | You'll need to close and reopen all .rs and Cargo files, or to restart the IDE, for this change to take effect. |
393 | 391 | ||
394 | == Configuration | 392 | == Configuration |
@@ -518,6 +516,20 @@ See https://github.com/rust-analyzer/rust-project.json-example for a small examp | |||
518 | 516 | ||
519 | You can set `RA_LOG` environmental variable to `rust_analyzer=info` to inspect how rust-analyzer handles config and project loading. | 517 | You can set `RA_LOG` environmental variable to `rust_analyzer=info` to inspect how rust-analyzer handles config and project loading. |
520 | 518 | ||
519 | == Security | ||
520 | |||
521 | At the moment, rust-analyzer assumes that all code is trusted. | ||
522 | Here is a **non-exhaustive** list of ways to make rust-analyzer execute arbitrary code: | ||
523 | |||
524 | * proc macros and build scripts are executed by default | ||
525 | * `.cargo/config` can override `rustc` with an arbitrary executable | ||
526 | * VS Code plugin reads configuration from project directory, and that can be used to override paths to various executables, like `rustfmt` or `rust-analyzer` itself. | ||
527 | * rust-analyzer's syntax trees library uses a lot of `unsafe` and hasn't been properly audited for memory safety. | ||
528 | |||
529 | rust-analyzer itself doesn't access the network. | ||
530 | The VS Code plugin doesn't access the network unless the nightly channel is selected in the settings. | ||
531 | In that case, the plugin uses the GitHub API to check for and download updates. | ||
532 | |||
521 | == Features | 533 | == Features |
522 | 534 | ||
523 | include::./generated_features.adoc[] | 535 | include::./generated_features.adoc[] |