Commit Graph

718 Commits

Author SHA1 Message Date
Aleksey Kladov
8716c4cec3 Move ide::AnalysisChange -> base_db::Change
This seems like a better factoring logically; ideally, clients shouldn't touch
`set_` methods of the database directly. Additionally, I think this
should remove the unfortunate duplication in fixture code.
2020-10-02 16:45:08 +02:00
Igor Aleksanov
4ebacf9024 Fix failing test 2020-10-02 12:35:25 +03:00
Igor Aleksanov
4a1b4b23bb Replace 'cargo_prefix' option with 'override_cargo' 2020-10-02 12:34:27 +03:00
Igor Aleksanov
2c125f3c63 Add support of runnables arguments in Rust Analyzer 2020-10-02 12:34:27 +03:00
Aleksey Kladov
af8063fe37 Extend **Status** command to also show dep info for the file
This should help with troubleshooting wrong project configuration
2020-09-29 22:13:23 +02:00
Aleksey Kladov
e7df0ad2fb Remove periodic gc stub 2020-09-29 21:22:48 +02:00
Aleksey Kladov
8e34c0fb73 More panic_context 2020-09-29 20:49:48 +02:00
Aleksey Kladov
d3a2b21a8c Add panic_context module for better panic messages 2020-09-29 20:20:47 +02:00
vsrs
91da41b3b1 Replace "No references" with "0 references". 2020-09-29 15:29:20 +03:00
vsrs
06fbd69050 Make method references CodeLens lazy. 2020-09-29 15:29:20 +03:00
vsrs
b7fda5f936 Make method references CodeLens off by default. 2020-09-29 15:29:20 +03:00
vsrs
eeb40dbece Add method references CodeLens 2020-09-29 15:29:20 +03:00
flw
e73ee9dfa2
Add hover config linksInHover to suppress links 2020-09-29 19:47:18 +08:00
Jonas Schievink
1a28f30ba4 Spawn a flycheck instance per workspace 2020-09-27 19:41:54 +02:00
kjeremy
95d7e3ce49 lsp-types 0.82 2020-09-23 15:41:55 -04:00
bors[bot]
e70cf706bb
Merge #6018
6018: Correct project_root path for ProjectJson. r=jonas-schievink a=woody77

It was already the folder containing the rust-project.json file, not the file itself.  This also removes the Option-ness of it, since it's now an infallible operation to set the member value.

Co-authored-by: Aaron Wood <aaronwood@google.com>
2020-09-20 19:25:09 +00:00
bors[bot]
fb1b0a4bff
Merge #6036
6036: Don't re-read open files from disk when reloading a workspace r=kjeremy a=lnicola

Fixes #5742
Fixes #4263

or so I hope.

Co-authored-by: Laurențiu Nicola <lnicola@dend.ro>
2020-09-18 21:29:47 +00:00
Laurențiu Nicola
5a0bad7754 Don't re-read open files from disk when reloading a workspace 2020-09-18 22:15:44 +03:00
kjeremy
c7243e4a59 Support active parameters at the per-signature level
Update crates
2020-09-18 11:39:25 -04:00
Jonas Schievink
d328ee647f Use log::error! in a few more places 2020-09-17 17:37:52 +02:00
bors[bot]
d84c18d989
Merge #6017
6017: Don't return any TextEdit if formatting is unchanged r=jonas-schievink a=cuviper

I found that `textDocument/formatting` was always returning a full
`TextEdit` replacement, even when there are no changes, which caused Vim
(w/ vim-lsp) to always indicate a modified buffer after formatting. We
can easily compare whether there were changes and return `null` if not,
so the client knows there's nothing to do.

Co-authored-by: Josh Stone <cuviper@gmail.com>
2020-09-17 13:08:09 +00:00
Aaron Wood
2fbb09a73f Correct project_root path for ProjectJson.
It was already the folder containing the rust-project.json file, not the file itself.
2020-09-16 12:09:44 -07:00
Josh Stone
29c3421391 Don't return any TextEdit if formatting is unchanged
I found that `textDocument/formatting` was always returning a full
`TextEdit` replacement, even when there are no changes, which caused Vim
(w/ vim-lsp) to always indicate a modified buffer after formatting. We
can easily compare whether there were changes and return `null` if not,
so the client knows there's nothing to do.
2020-09-16 10:05:41 -07:00
Aaron Wood
74c26a785a Add support for custom flycheck commands with JSON project workspaces
Enable flychecks with JSON project workspaces if an override command was provided as part
of the client configuration.
2020-09-15 18:51:57 -07:00
Lukas Wirth
adc4c6b9d7 Make MergeBehaviour configurable 2020-09-12 12:11:16 +02:00
Jonas Schievink
681ac6294a Report better errors in project.json/sysroot 2020-09-11 14:48:56 +02:00
Igor Aleksanov
023e3a1dea Highlight errors in macros 2020-09-06 09:22:01 +03:00
Andy Russell
24805d1d80
default checkOnSave.enable to true in server 2020-09-02 17:44:21 -04:00
kjeremy
36692bdffa Switch to upstream ENUM_MEMBER 2020-09-02 09:40:59 -04:00
kjeremy
b527257330 Move to vscode-languageclient 7.0.0-next.9
Stabilizes call hierarchy and semantic tokens features.
2020-09-02 09:40:59 -04:00
Kirill Bulatov
3ac9732ca3 Fix some typos 2020-08-28 21:55:24 +03:00
Aleksey Kladov
c692b5d76d ⬆️ expect-test 2020-08-28 14:47:14 +02:00
Jonas Schievink
964219f0be Allow running a test as a binary 2020-08-26 17:33:03 +02:00
León Orell Valerian Liehr
63caef372a Improve support for code block attributes 2020-08-26 15:55:06 +02:00
Aleksey Kladov
7431ec82c9 Simplify 2020-08-26 13:40:45 +02:00
Aleksey Kladov
ed6304131a Simplify 2020-08-26 13:20:46 +02:00
Aleksey Kladov
bb50614d88 Simplify help 2020-08-26 13:20:46 +02:00
Aleksey Kladov
a53c6f6fee Allow redirecting logs to a specific file
There's a surprising lack of crates which are like env_logger, but
also allow writing to a file. Let's write our own then!
2020-08-26 13:20:46 +02:00
Aleksey Kladov
c6dffe479b Cleanup heavy tests 2020-08-25 19:26:45 +02:00
bors[bot]
59c77ff062
Merge #5866
5866: Improve logging
 r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2020-08-25 09:46:21 +00:00
Aleksey Kladov
3a72afed8c Improve logging 2020-08-25 11:43:21 +02:00
Zac Pullar-Strecker
b835f06cec Merge remote-tracking branch 'upstream/master' into 503-hover-doc-links 2020-08-25 16:44:36 +12:00
Pavan Kumar Sunkara
b2d43daeb4 Allow rust-analyzer auto publishing 2020-08-24 17:27:17 +02:00
Zac Pullar-Strecker
7bbca7a1b3 Merge remote-tracking branch 'upstream/master' into 503-hover-doc-links 2020-08-24 21:20:13 +12:00
Pavan Kumar Sunkara
a8fa5cd42e Add version to deps in cargo.toml 2020-08-24 11:10:41 +02:00
Aleksey Kladov
b0fd3faf36 Switch to expect_test from crates.io 2020-08-21 13:19:31 +02:00
bors[bot]
529ca7e5e0
Merge #5643
5643: Add new consuming modifier, apply consuming and mutable to methods r=matklad a=Nashenas88

This adds a new `consuming` semantic modifier for syntax highlighters.

This also emits `mutable` and `consuming` in two cases:

- When a method takes `&mut self`, then it now has `function.mutable` emitted.
- When a method takes `self`, and the type of `Self` is not `Copy`, then `function.consuming` is emitted.

CC @flodiebold 

Co-authored-by: Paul Daniel Faria <Nashenas88@users.noreply.github.com>
2020-08-19 11:27:02 +00:00
bors[bot]
0df9ecedb4
Merge #5798
5798: Introduce Label
 r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2020-08-18 14:51:10 +00:00
Aleksey Kladov
aa1a7a5414 Introduce Label 2020-08-18 16:50:07 +02:00
bors[bot]
0e66dc690e
Merge #5796
5796: Align diagnostics config with the rest of rust-analyzer
 r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2020-08-18 14:12:00 +00:00