bors
a616c4d117
Auto merge of #16356 - Veykril:sysroot-metadata, r=Veykril
...
internal: Add unstable config for loading the sysroot sources via `cargo metadata`
cc https://github.com/rust-lang/rust-analyzer/issues/7637
This takes the approach of having `cargo metadata` generate a lock file that we then delete again, hence why this is behind a flag. If people need this for their workflow they can just enable it, if not, they are probably better off keeping it disabled. [example](https://dreampuf.github.io/GraphvizOnline/#digraph%20rust_analyzer_crate_graph%20%7B%0A%20%20%20%20_0%5Blabel%3D%22core%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_17%5Blabel%3D%22ra_playground%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_14%5Blabel%3D%22getopts%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_11%5Blabel%3D%22std_detect%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_8%5Blabel%3D%22unwind%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_5%5Blabel%3D%22hashbrown%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_2%5Blabel%3D%22alloc%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_16%5Blabel%3D%22test%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_13%5Blabel%3D%22unicode_width%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_10%5Blabel%3D%22rustc_demangle%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_7%5Blabel%3D%22panic_abort%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_4%5Blabel%3D%22cfg_if%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_1%5Blabel%3D%22compiler_builtins%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_18%5Blabel%3D%22build_script_build%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_15%5Blabel%3D%22proc_macro%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_12%5Blabel%3D%22std%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_9%5Blabel%3D%22panic_unwind%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_6%5Blabel%3D%22libc%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_3%5Blabel%3D%22allocator_api2%22%5D%5Bshape%3D%22box%22%5D%3B%0A%20%20%20%20_17%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_17%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_17%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_17%20-%3E%20_15%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_17%20-%3E%20_16%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_14%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_14%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_14%20-%3E%20_13%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_11%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_11%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_11%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_11%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_11%20-%3E%20_6%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_8%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_8%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_8%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_8%20-%3E%20_6%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_5%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_5%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_5%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_5%20-%3E%20_3%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_2%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_2%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_16%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_16%20-%3E%20_7%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_16%20-%3E%20_9%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_16%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_16%20-%3E%20_14%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_13%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_13%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_13%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_10%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_10%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_7%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_7%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_7%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_7%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_7%20-%3E%20_6%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_1%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_18%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_18%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_18%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_18%20-%3E%20_15%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_18%20-%3E%20_16%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_15%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_15%20-%3E%20_12%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_5%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_6%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_7%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_8%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_9%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_10%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_12%20-%3E%20_11%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_1%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_2%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_4%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_6%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_9%20-%3E%20_8%5Blabel%3D%22%22%5D%3B%0A%20%20%20%20_6%20-%3E%20_0%5Blabel%3D%22%22%5D%3B%0A%7D%0A )
![image](https://github.com/rust-lang/rust-analyzer/assets/3757771/7709bb38-d948-4106-82c2-9b76677620bd )
hashbrown resolves as a dependency now
2024-01-15 09:12:10 +00:00
Lukas Wirth
c7eb52dd7b
internal: Add unstable config for loading the sysroot sources via cargo metadata
2024-01-15 09:59:32 +01:00
David Tolnay
02d21f21cf
Add a stable #visual-studio anchor to the Manual
2024-01-14 10:54:20 -08:00
Johann Hemmann
d94f572fe2
Remove newline and add dot
2024-01-08 18:10:48 +01:00
riverbl
3c378b9c70
Add inlay hint for exclusive ranges
...
Adds an inlay hint containing a '<' character to exclusive range expressions and patterns that specify an upper bound.
2024-01-07 09:33:56 +00:00
bors
1c6755cad0
Auto merge of #16213 - davidsemakula:guide-typos-urls, r=lnicola
...
chore: update docs/dev/guide.md based on 2024-01-01 release
Updates dev guide based on 2024-01-01 release
2024-01-05 13:03:41 +00:00
Laurențiu Nicola
03ec0087a0
Tweak wording a little more
2024-01-05 10:24:39 +02:00
davidsemakula
7c259a0300
fix typos and update descriptions
2024-01-05 01:56:06 +03:00
Paul Jewell
443787fe6a
Added reference to the binaries available from GitHub.
...
In addition to installing from source.
2024-01-04 21:37:07 +00:00
Paul Jewell
0d6ec9c987
Further tuning of the Gentoo installation instructions.
...
based on feedback from the Gentoo repository maintainer, addition of
the possibility to install rust-analyzer via rustup.
2024-01-04 21:16:03 +00:00
davidsemakula
f098123122
update docs/dev/guide.md based on 2024-01-01 release
2024-01-04 20:57:50 +03:00
Laurențiu Nicola
570ee51d50
Tweak Gentoo instructions
2024-01-03 16:05:00 +02:00
bors
91ffbd7788
Auto merge of #15922 - paul-jewell:master, r=Veykril
...
Updated instructions for installing rust-analyzer under Gentoo.
No need to install the guru overlay to install rust-analyzer. This is now installed based on use flag settings for dev-lang/rust and dev-lang/rust-bin. This pull request changes the instructions in the user manual.
Note: rust-analyzer is not available in the guru repository, so the old instructions no longer work.
2024-01-03 13:38:37 +00:00
bors
22f189b6bb
Auto merge of #16228 - Veykril:arch.md, r=Veykril
...
minor: Add some more crates to architecture.md
2024-01-02 11:33:53 +00:00
Lukas Wirth
16457abe0e
Add some more crates to architecture.md
2024-01-02 12:32:20 +01:00
bors
9f46ff501d
Auto merge of #16062 - davidbarsky:david/fix-references-to-removed-settings, r=Veykril
...
fix: Correct references from `rust-analyzer.cargo.check` to `rust-analyzer.check`
When reading the manual, I noticed that the documentation referenced configurations that have since been renamed. This PR updates those references to their new names.
2024-01-02 09:57:48 +00:00
bors
f1de7d7273
Auto merge of #16011 - ClSlaid:feat/settings/proc-macro/rebuild-on-save, r=Veykril
...
feat: add proc-macro rebuild on save option
Related: #15033
I need some advice on how to test it.
2024-01-02 09:46:21 +00:00
davidsemakula
52f7575c35
minor: chore: fix typos and urls in docs/dev/guide.md
2023-12-29 20:49:22 +03:00
Lukas Wirth
2a5b60b186
internal: Update world symbols request definiton, prefer focus range for macros
2023-12-22 11:42:08 +01:00
David Barsky
f556c79db8
fix: Correct references from rust-analyzer.cargo.check
to rust-analyzer.check
2023-12-08 14:26:58 -05:00
蔡略
ad27b6e053
patch: only rerun build scripts when saved.
...
Signed-off-by: 蔡略 <cailue@bupt.edu.cn>
2023-12-08 11:31:56 +08:00
hkalbasi
4d55cac466
Initial support for implicit drop inlay hint
2023-12-01 16:16:46 +03:30
Dash Lu
9f8191b62d
Update Arch Linux package URL in manual.adoc
2023-11-21 22:41:49 +08:00
Paul Jewell
331abe2d1f
Updated instructions for installing rust-analyzer under Gentoo.
2023-11-17 14:41:34 +00:00
bors
416e9c856a
Auto merge of #15881 - nokazn:docs/fix-vscode-setting-samples, r=lnicola
...
docs: fix VS Code setting samples
Fix invalid JSONC examples (missing double quotes) in VS Code's `settings.json` .
Thank you.
2023-11-12 17:07:42 +00:00
Lukas Wirth
d6b908ec41
Fix import preference config keys
2023-11-12 17:48:40 +01:00
bors
92d9ca7d64
Auto merge of #15876 - DropDemBits:lsp-ext-multiple-snippet-textedit, r=Veykril
...
minor: Allow multiple snippet edits in a `TextDocumentEdit`
Explicitly[^1] allow a single `TextDocumentEdit` to have multiple `SnippetTextEdit`s. This allows things like renaming extracted variables and functions without having to go through a separate rename step. For an example of what this looks like, see the video in [this comment](https://github.com/microsoft/vscode/issues/145374#issuecomment-1177341711 ).
The behavior described here lines up with [what VSCode does](bdc113ffe1/src/vscode-dts/vscode.d.ts (L3728-L3731)
), and presumably what the eventual LSP behavior will be.
[^1]: This was technically the case before #15269 , a single `TextDocumentEdit` always had multiple edits which were `InsertTextFormat.Snippet` as all of the edits were marked as being snippets, even if there weren't any tab stops or placeholders.
2023-11-12 15:20:42 +00:00
DropDemBits
1e4686865e
Allow multiple snippet edits in a TextDocumentEdit
2023-11-11 22:12:49 -05:00
nokazn
b6f0994ee6
docs: fix VS Code setting samples
2023-11-12 10:29:56 +09:00
Lukas Wirth
ba61766217
Add config for preferring / ignoring prelude modules in find_path
2023-11-11 14:56:38 +01:00
Sarrus1
9d290f1d4c
chore: fix urls in guide.md
2023-10-30 19:40:24 +01:00
Wilfred Hughes
03bec1112a
Expand Emacs documentation
...
Emacs 29 is now released, and include an example of enabling clippy.
2023-10-15 16:34:23 -07:00
Piotr Osiewicz
2e713a7a2f
docs: Add Zed to IDE list.
2023-10-11 15:45:16 +02:00
Victor Song
a39d2076db
Addressed PR style comments
2023-10-09 02:15:05 -05:00
Victor Song
ef0b3bbef1
Clarify documentation on new parameter
2023-10-09 02:15:05 -05:00
Victor Song
aeef7b644b
Add config option to use rust-analyzer
specific target dir
...
Adds a Rust Analyzer configuration option to set a custom
target directory for builds. This is a workaround for Rust Analyzer
blocking debug builds while running `cargo check`. This change
should close #6007
2023-10-09 02:15:05 -05:00
bors
e5e937ae5e
Auto merge of #15582 - vxpm:master, r=HKalbasi
...
add option to show full function signatures in completion docs
implements #15538
with `"rust-analyzer.completion.fullFunctionSignatures.enable": false`:
![image](https://github.com/rust-lang/rust-analyzer/assets/59714841/ff739ad1-9975-461f-a62d-22c7823e7b71 )
with `"rust-analyzer.completion.fullFunctionSignatures.enable": true`:
![image](https://github.com/rust-lang/rust-analyzer/assets/59714841/9bc98300-cef6-44ef-a353-dcf35cd36fce )
2023-09-24 07:38:38 +00:00
bors
2b580a1f3c
Auto merge of #15492 - RalfJung:invocation, r=Veykril
...
extend check.overrideCommand and buildScripts.overrideCommand docs
Extend check.overrideCommand and buildScripts.overrideCommand docs regarding invocation strategy and location.
However something still seems a bit odd -- the docs for `invocationStrategy`/`invocationLocation` talk about "workspaces", but the setting that controls which workspaces are considered is called `linkedProjects`. Is a project the same as a workspace here or is there some subtle difference?
2023-09-22 16:09:01 +00:00
Lukas Wirth
ba7f2bfb85
Update config docs
2023-09-22 17:46:17 +02:00
vxpm
6b487ed4be
fix & run tests
2023-09-08 22:03:42 -03:00
Kirill Bulatov
e07fbabcfe
Resolve inlay hint data
...
Skip every propery set in inlay hint client resolve capabilities,
reducing overall json footprint.
2023-09-02 18:28:35 +03:00
Lukas Wirth
2dbc7e3e1a
Restructure some modules in rust-analyzer crate
2023-09-02 14:16:04 +02:00
Lukas Wirth
ea74cc4b9a
Update architecture.md
2023-08-30 19:53:47 +02:00
Ralf Jung
887cc48ba8
fix help text for rust-analyzer.check.invocation{Strategy,Location}
2023-08-21 09:54:24 +02:00
bors
e13fac379e
Auto merge of #15262 - adamse:master, r=HKalbasi
...
add check.ignore to list cargo check diagnostics to ignore (dead_code, unused_imports, ...)
fixes #14798
2023-08-08 18:49:45 +00:00
Adam Sandberg Ericsson
9cb1f45e6f
add check.ignore to list cargo check diagnostics to ignore (dead_code, unused_imports, ...)
...
fixes #14798
2023-08-08 14:28:35 +02:00
bors
bc1b0bfa7f
Auto merge of #15308 - vsrs:runnable_env_per_platform, r=HKalbasi
...
Runnable env per platform
This PR adds an option to specify runnables `env` per platform (win32, linux, etc.):
```
{
"rust-analyzer.runnables.extraEnv": [
{
"platform": "win32",
"env": {
"SCITER_BIN_FOLDER": "C:\\Projects\\3rd\\sciter-js-sdk\\bin\\windows\\x64",
}
},
{
"platform":["linux","darwin"],
"env": {
"SCITER_BIN_FOLDER": "/home/vit/Projects/sciter/sciter-js-sdk/bin/linux/x64",
}
}
]
}
```
2023-07-28 07:03:09 +00:00
prez
b6f31f0fee
docs: Add example on how to change configuration options in Kate
2023-07-20 11:47:41 +02:00
vsrs
7f29f016f3
Add docs
2023-07-18 17:58:51 +07:00
Adenine
add9056c32
Merge branch 'rust-lang:master' into master
2023-07-09 16:10:40 -04:00
Laurențiu Nicola
8befd920d6
Remove old section about downloading the server from the manual
2023-07-09 09:26:05 +03:00
Adenine
1dd54eb44a
change viewMemoryLayoutParams to be textPositionParams
2023-07-08 12:25:54 -04:00
Adenine
514bab504e
Merge branch 'rust-lang:master' into master
2023-07-08 12:21:38 -04:00
Ali Bektas
2e5d431dfc
Update docs/user/manual.adoc
...
Co-authored-by: Laurențiu Nicola <lnicola@users.noreply.github.com>
2023-07-08 16:15:08 +02:00
Ali Bektas
655dd188d6
Remind user to check $PATH after installation.
2023-07-08 11:59:46 +02:00
Adenine
4d5c66986e
cleanup + docs + tests
2023-07-07 23:12:09 -04:00
Mohsen Alizadeh
6c3e15aaa0
13583 rename runnable env to runnables extra env
2023-06-25 17:26:04 -07:00
Laurențiu Nicola
8589a8100a
Neovim, not NeoVim
2023-06-23 20:00:53 +02:00
Alex Kladov
6303551cb8
internal: use consistent style for error handling
2023-06-19 13:01:47 +01:00
MysticNebula70
8cc55bfee6
doc: remove duplicated words
2023-06-16 18:22:43 +08:00
Wilfred Hughes
5da14237eb
Document the sysroot field in JsonProject
...
rust-analyzer supports both `sysroot` and `sysroot_src` in
`rust-project.json`. Document `sysroot` and show example values for
both fields.
2023-06-08 14:56:37 -07:00
Lukas Wirth
3c862507b9
Add render configs for memory layout hovers
2023-05-30 18:36:06 +02:00
bors
e8dbb8e2e0
Auto merge of #14911 - Veykril:config-cfg, r=Veykril
...
Allow setting cfgs
Fixes https://github.com/rust-lang/rust-analyzer/issues/14365
2023-05-30 12:00:14 +00:00
Lukas Wirth
cea84427e0
Allow setting cfgs
2023-05-28 13:43:21 +02:00
Mason Shuler
05d63eff9c
Make rustup heading title match other titles
2023-05-26 16:41:51 -04:00
Mason Shuler
def3b5d7dd
Remove outdated rustup installation issue description
2023-05-26 16:40:30 -04:00
Lukas Wirth
91d5a689c7
Add config for disabling non standard lsp highlight tokens
2023-05-11 10:01:38 +02:00
bors
d3ce333ec8
Auto merge of #14742 - Veykril:closure-capture-inlays, r=Veykril
...
feat: Closure capture inlay hints
I opted for a fictional `move(foo, &bar, &mut qux)` syntax here, disabled by default as these are not correct rust syntax and hence could cause confusion.
![image](https://user-images.githubusercontent.com/3757771/236447484-649a4ea6-ad61-496e-bad8-765a5236150e.png )
2023-05-08 09:52:29 +00:00
Yury Ivanou
98a4c5049f
Rename hover memory layout config key
2023-05-07 18:37:56 +03:00
Yury Ivanou
4ed0fa8414
Add config for disabling hover memory layout data
2023-05-07 18:21:07 +03:00
Lukas Wirth
8081a654da
feat: Closure capture inlay hints
2023-05-05 13:38:22 +02:00
Ddystopia
7e19d99d4f
Add a localDocs
capability
2023-05-02 17:13:21 +02:00
Ddystopia
b74b9797bc
Update hash in lsp-extensions.md
2023-05-02 17:08:54 +02:00
Ddystopia
da0ffe79d0
Change signature of externalDocs
in lsp-extensions
2023-05-02 17:06:39 +02:00
Bruno Ortiz
ecfe7c0488
last fixes after rebase
2023-05-02 11:24:08 -03:00
Bruno Ortiz
66fe84d936
accepting review suggestions
2023-05-02 11:01:41 -03:00
Bruno Ortiz
1b8288ff96
Fixing naming from graph to list
2023-05-02 10:59:29 -03:00
Bruno Ortiz
e2535926e9
Fixing tests
2023-05-02 10:56:50 -03:00
Lukas Wirth
a64626d99e
Highlight closure captures when cursor is on pipe
2023-05-02 08:59:40 +02:00
hkalbasi
6312fbf521
MIR episode 4
2023-05-01 23:23:10 +03:30
wtj
c533ac3573
minor: fix typos
2023-04-28 18:49:05 +08:00
Lukas Wirth
c21860bd6a
Remove proc-macro server command from the rust-analyzer binary
2023-04-26 08:19:28 +02:00
Josh Soref
bc7d84c3ce
Spelling
...
* a rule
* access
* after
* amount
* annotations
* assignment
* assist
* associated
* attribute
* borrowed
* built-in type
* clarification
* command
* const
* constructor
* corresponding
* counterparts
* curlies
* dependencies
* deterministic
* diagnostic
* duplicates
* edge
* edited
* efficient
* elsewhere
* execution
* expression
* extensions
* extracted
* fill
* github
* helper
* heuristic
* incomplete
* indent end
* inlay
* invocation
* lifetime
* looking
* maybe
* move
* mutability
* mutable
* necessarily
* necessary
* negative
* nonexistent
* occurred
* offsets
* offsetted
* overridden
* parameters
* params
* params_and_where_preds_in_scope
* paredit
* parent
* parentheses
* prepended if
* punctuation
* receive
* receiver
* referring
* repeated
* representing
* semantically
* separately
* shouldnot
* siblings
* similar
* something's
* statement
* struct
* structure
* surprise
* the
* this
* transparent
* unimplemented
* unnamed
* unnecessary
* unneeded
* unreachable
* unterminated
* utilities
* variant
* variants
* visibility
* work around (v)
* workaround
Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2023-04-19 09:45:55 -04:00
Lukas Wirth
0286e46e5f
internal: Skip code lens resolution for mismatched document versions
2023-04-13 10:55:28 +02:00
hkalbasi
59b6f2d9f2
Compute closure captures
2023-04-10 23:04:34 +03:30
bors
fc8c5139fa
Auto merge of #14410 - Veykril:query-lru-capacities, r=Veykril
...
internal: Add config to specifiy lru capacities for all queries
Might help figuring out what queries should be limited by LRU by default, as currently we only limit `parse`, `parse_macro_expansion` and `macro_expand`.
2023-03-30 12:20:24 +00:00
Lukas Wirth
5616d91b73
internal: Add config to specifiy lru capacities for all queries
2023-03-30 12:52:28 +02:00
Lukas Wirth
ee02213e65
Handle proc macro fetching via OpQueue
2023-03-26 09:33:41 +02:00
Lukas Wirth
586db0790c
minor: Add user facing command for reloading proc-macros in VSCode
2023-03-25 20:54:24 +01:00
Lukas Wirth
607375dc20
Load proc-macros asynchronously
2023-03-25 18:06:06 +01:00
Laurențiu Nicola
c3864eb511
Add and use rust-analyzer.cargo.extraArgs setting
2023-03-12 13:04:24 +02:00
hkalbasi
ac04bfd7a7
Add View Mir
command and fix some bugs
2023-03-06 21:09:09 +03:30
bors
a0be16b0b2
Auto merge of #14040 - HKalbasi:mir, r=HKalbasi
...
Beginning of MIR
This pull request introduces the initial implementation of MIR lowering and interpreting in Rust Analyzer.
The implementation of MIR has potential to bring several benefits:
- Executing a unit test without compiling it: This is my main goal. It can be useful for quickly testing code changes and print-debugging unit tests without the need for a full compilation (ideally in almost zero time, similar to languages like python and js). There is a probability that it goes nowhere, it might become slower than rustc, or it might need some unreasonable amount of memory, or we may fail to support a common pattern/function that make it unusable for most of the codes.
- Constant evaluation: MIR allows for easier and more correct constant evaluation, on par with rustc. If r-a wants to fully support the type system, it needs full const eval, which means arbitrary code execution, which needs MIR or something similar.
- Supporting more diagnostics: MIR can be used to detect errors, most famously borrow checker and lifetime errors, but also mutability errors and uninitialized variables, which can be difficult/impossible to detect in HIR.
- Lowering closures: With MIR we can find out closure capture modes, which is useful in detecting if a closure implements the `FnMut` or `Fn` traits, and calculating its size and data layout.
But the current PR implements no diagnostics and doesn't support closures. About const eval, I removed the old const eval code and it now uses the mir interpreter. Everything that is supported in stable rustc is either implemented or is super easy to implement. About interpreting unit tests, I added an experimental config, disabled by default, that shows a `pass` or `fail` on hover of unit tests (ideally it should be a button similar to `Run test` button, but I didn't figured out how to add them). Currently, no real world test works, due to missing features including closures, heap allocation, `dyn Trait` and ... so at this point it is only useful for me selecting what to implement next.
The implementation of MIR is based on the design of rustc, the data structures are almost copy paste (so it should be easy to migrate it to a possible future stable-mir), but the lowering and interpreting code is from me.
2023-02-28 09:12:19 +00:00
hkalbasi
cd67589f63
beginning of MIR
2023-02-27 23:45:54 +03:30
Laurențiu Nicola
563bd9c24a
Try to improve the rustfmt.overrideCommand docs
2023-02-21 12:43:22 +02:00
Ethan-000
936bac31d4
fix link
2023-02-16 21:45:56 +00:00
Aleksey Kladov
0da27376cf
Support UTF-32 position encoding
...
Looks like this is a native encoding for Emacs at least!
2023-02-14 01:09:50 +00:00
bors
646f973857
Auto merge of #14134 - lnicola:clippy-manual, r=Veykril
...
feat: Add clippy configuration section to the manual and update some old keys
Closes #14132
I don't think this is supposed to be under `Diagnostics`, but it does make sense in a way 🤷 (it's probably where someone might look).
2023-02-12 09:53:15 +00:00
Laurențiu Nicola
8f617b55ce
Update some old checkOnSave references
2023-02-12 11:35:44 +02:00
Laurențiu Nicola
cfeec8a705
Add clippy configuration section to the manual
2023-02-12 11:34:52 +02:00