DJMcNab
4dbf71d332
Remove uneeded todo in lexer
2018-12-21 22:41:09 +00:00
DJMcNab
d8d60215da
Fix handling of nested self in paths
2018-12-21 22:29:59 +00:00
bors[bot]
184665ff9b
Merge #315
...
315: Split completion into manageable components r=matklad a=matklad
The main idea here is to do completion in two phases:
* first, we figure out surrounding context
* then, we run a series of completers on the given context.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-21 22:04:32 +00:00
Aleksey Kladov
2ae87ffc9a
cleanup
2018-12-22 01:03:58 +03:00
Aleksey Kladov
a8e04a7028
docs
2018-12-22 01:01:40 +03:00
Aleksey Kladov
200cc0a1e3
rename tests
2018-12-22 00:55:20 +03:00
Aleksey Kladov
ccca5aae43
scope-based copmletions on original file
2018-12-22 00:52:02 +03:00
Aleksey Kladov
2136e75c0b
move path completion to a separate component
2018-12-21 23:04:56 +03:00
Aleksey Kladov
2351308d92
remove explicit serde_derive
2018-12-21 22:39:59 +03:00
Aleksey Kladov
67ac0a423f
join lines collapses use_trees
2018-12-21 21:06:01 +03:00
Aleksey Kladov
cbe67339df
more completion components
2018-12-21 20:55:00 +03:00
bors[bot]
a106784115
Merge #313
...
313: Fix where clauses using fully qualified path syntax r=matklad a=DJMcNab
Fixes #311 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-21 17:31:43 +00:00
Aleksey Kladov
c2bf174e9c
Start splitting completion into components
2018-12-21 20:25:29 +03:00
DJMcNab
bd5a358910
Fix where clauses using fully qualified path syntax
2018-12-21 17:20:38 +00:00
DJMcNab
380733d6d0
Undo the previous mistaken change and make publish_decorations optional
...
See https://github.com/Microsoft/language-server-protocol/issues/567
for motivations to not require `InitializationOptions`
TODO: Check if there are any other protocol extensions
which should be disabled if not implemented on the client
2018-12-21 17:00:31 +00:00
Aleksey Kladov
e086cc8db5
hide empty changes
2018-12-21 19:13:26 +03:00
Aleksey Kladov
12810b93c5
wip
2018-12-21 19:10:07 +03:00
Aleksey Kladov
9de3a45be6
add tests for pd
2018-12-21 18:53:00 +03:00
Aleksey Kladov
a5987bd715
show debug repr of literals
2018-12-21 18:49:52 +03:00
bors[bot]
0dcea10616
Merge #312
...
312: Completion refactoring r=matklad a=matklad
Just a usual refactoring, turning a rather ad-hoc completion infra into something extensible
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-21 15:14:34 +00:00
Aleksey Kladov
45232dfa68
organize completion tests better
2018-12-21 18:13:21 +03:00
gfreezy
66d15bb2da
add #[cfg(test)]
2018-12-21 22:45:38 +08:00
gfreezy
77eaa208ed
rename to dfs_find
2018-12-21 22:30:41 +08:00
gfreezy
792dabc0a6
When constructing a crate graph, detect and forbid cycles.
...
fixed #300
2018-12-21 22:27:04 +08:00
Aleksey Kladov
d4ef07b235
use completions in API
2018-12-21 15:50:07 +03:00
Aleksey Kladov
ba0072401c
use Completions to collect completions
2018-12-21 15:46:01 +03:00
Aleksey Kladov
052e20162a
docs
2018-12-21 15:34:11 +03:00
Aleksey Kladov
0ce82516c1
introduce Completions
2018-12-21 15:32:29 +03:00
Aleksey Kladov
4092b8d0b5
make compleion item details private
2018-12-21 15:19:46 +03:00
Aleksey Kladov
b5c5995bf1
use builder interface for completion item
2018-12-21 14:38:41 +03:00
Aleksey Kladov
b0ff6176ed
flip params
2018-12-21 14:02:51 +03:00
Aleksey Kladov
74406ca8ea
introduce completion_item module
2018-12-21 14:02:14 +03:00
bors[bot]
463e5af3f2
Merge #306
...
306: Finish weird exprs r=DJMcNab a=DJMcNab
Fix #290 .
Note that I'm not certain my use of `p.nth(1) == Ident` is entirely consistent with `libsyntax` - in the original, [`is_union_item`](9622f9dc47/src/libsyntax/parse/parser.rs (L4593-L4596)
) uses `t.is_ident() && !t.is_reserved_ident()`, whereas we effectively only do `is_ident`. However, I cannot find the definition of `is_reserved_ident` (even searching the rust repository only gives uses, no definitions), so this will have to do unless someone else can find it :|.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-21 10:04:00 +00:00
DJMcNab
9beee92500
Add comment about the source of the weird_exprs test
2018-12-21 10:03:02 +00:00
bors[bot]
4f7ec01703
Merge #309
...
309: Fix edits r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-21 09:33:45 +00:00
Aleksey Kladov
fd927ea3a9
use root-relative paths
2018-12-21 12:30:28 +03:00
Aleksey Kladov
b5b44659a4
edits use source-root API
2018-12-21 12:18:14 +03:00
Aleksey Kladov
0063f03e86
hide atom edits a bit
2018-12-21 11:52:32 +03:00
Aleksey Kladov
164d53b22f
better debug impls
2018-12-21 11:49:18 +03:00
Aleksey Kladov
aa628f4749
fix SourceFileEdit name
2018-12-21 11:15:23 +03:00
bors[bot]
f897de5b78
Merge #308
...
308: tweak canceled message r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-21 08:09:36 +00:00
Aleksey Kladov
b7d8bf1262
tweak canceled message
2018-12-21 11:08:43 +03:00
bors[bot]
f1fafeee02
Merge #305 #307
...
305: Fold curly blocks r=matklad a=matklad
307: ⬆️ 1.31.1 r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-20 19:58:10 +00:00
Aleksey Kladov
2956e81295
⬆️ 1.31.1
2018-12-20 22:57:38 +03:00
DJMcNab
da6be9fdda
Add weird_exprs test
2018-12-20 19:47:29 +00:00
DJMcNab
55ebe449c9
Fix parsing of contextual_keyword union
2018-12-20 19:46:03 +00:00
Aleksey Kladov
23b040962f
fold curly blocks
2018-12-20 22:43:06 +03:00
Aleksey Kladov
8d7e8a175e
generalize folding tests
...
By using xml-like tags, we will be able to test nested foldings.
2018-12-20 22:30:30 +03:00
bors[bot]
61dcaa6add
Merge #304
...
304: Support a blank expression before a semicolon r=DJMcNab a=DJMcNab
Part of fixing #290 .
Note that I have not run `gen-tests` as I don't want to conflict with #299 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-20 19:12:17 +00:00
DJMcNab
a349db7178
Run gen-tests
2018-12-20 19:10:37 +00:00