gfreezy
bc0f79f74a
rename mod
2019-01-19 15:36:58 +03:00
Aleksey Kladov
b82fe73d1a
make token set a const-fn
2019-01-19 15:36:58 +03:00
Aleksey Kladov
b028472481
⬆️ update rust
2019-01-19 15:36:58 +03:00
Aleksey Kladov
a2ca03d10b
⬆️ salsa
2019-01-17 14:11:00 +03:00
Hirokazu Hata
0aedd4fb2f
Add Ty::Array to walk_mut
2019-01-17 00:08:53 +09:00
Hirokazu Hata
f66ca1bd2e
Fix test case invalid syntax
2019-01-16 23:39:14 +09:00
Hirokazu Hata
5c570fa770
Remove unneeded code
2019-01-16 23:39:14 +09:00
Hirokazu Hata
478ce1c8b5
Fix infer array test
2019-01-16 23:37:42 +09:00
Hirokazu Hata
5d3884d5b4
Fix Ty::Array
2019-01-16 23:37:42 +09:00
Hirokazu Hata
2a3262c757
Add infer array test
2019-01-16 23:35:06 +09:00
Hirokazu Hata
d665acbbec
Implement array inference
2019-01-16 23:35:06 +09:00
Hirokazu Hata
4729a1b054
Update ARRAY_EXPR grammar
2019-01-16 23:22:14 +09:00
bors[bot]
d75a0368f5
Merge #536
...
536: Introduce variable semicolon block expr r=matklad a=yerke
Fix for https://github.com/rust-analyzer/rust-analyzer/issues/504
Feels a bit hacky...
Co-authored-by: Yerkebulan Tulibergenov <yerkebulan@gmail.com>
2019-01-16 06:20:09 +00:00
Yerkebulan Tulibergenov
67ddd33598
don't need SEMI any more
2019-01-15 20:29:37 -08:00
Yerkebulan Tulibergenov
de7c0f814c
delete unused fn
2019-01-15 20:28:01 -08:00
Yerkebulan Tulibergenov
4dd7ec94bc
use has_semi
2019-01-15 20:27:15 -08:00
Yerkebulan Tulibergenov
5e35f191fc
add has_semi to ExprStmt
2019-01-15 20:26:46 -08:00
Marcus Klaas de Vries
a2b6d3da30
Implement rudimentary type inference for unary operators
2019-01-16 00:04:39 +01:00
Aleksey Kladov
8338acfd3a
kill last cancelables
2019-01-15 21:17:10 +03:00
Aleksey Kladov
0bb170a277
remove Canceled from impl of ra_ide_api
2019-01-15 21:09:51 +03:00
Aleksey Kladov
05ba45c667
remove Canceled from API impl
2019-01-15 21:02:42 +03:00
Aleksey Kladov
02c3d2f78e
hir is cancelation free
2019-01-15 20:56:06 +03:00
Aleksey Kladov
8ba9c2d4ce
remove Cancelable from type inference
2019-01-15 20:54:18 +03:00
Aleksey Kladov
b871062e32
remove Cancelable from Ty
2019-01-15 20:43:37 +03:00
Aleksey Kladov
fafcd103d2
remove Cancelable from ids
2019-01-15 19:18:52 +03:00
Aleksey Kladov
490112dea1
remove Cancelable from nameres
2019-01-15 19:15:01 +03:00
Aleksey Kladov
18e9a710cd
remove Cancelable from fn_scopes
2019-01-15 19:04:49 +03:00
Aleksey Kladov
040a622c52
remove Cancelable from funciton body
2019-01-15 19:01:59 +03:00
Aleksey Kladov
f1367e0370
remove Cancelable from navigation target
2019-01-15 18:50:16 +03:00
Aleksey Kladov
9dd4099d93
remove Cancelable from static&const API
2019-01-15 18:45:01 +03:00
Aleksey Kladov
9446be2999
remove Cancelable from adt API
2019-01-15 18:43:25 +03:00
Aleksey Kladov
8af9a18660
remove Cancelable from Crate API
2019-01-15 18:33:26 +03:00
Aleksey Kladov
c159e414b4
remove Cancelable from Module API, part 2
2019-01-15 18:30:58 +03:00
Aleksey Kladov
ca52cf1ecd
remove Cancelable from Module API
2019-01-15 18:26:29 +03:00
Aleksey Kladov
fb012e5c1e
remove cancelable from symbols
2019-01-15 18:19:09 +03:00
Aleksey Kladov
11f3c8afb2
remove Cancelable from source binders
2019-01-15 18:13:49 +03:00
Aleksey Kladov
68ff52566d
remove Cancelable from module_tree_query
2019-01-15 17:55:15 +03:00
Aleksey Kladov
fedd320cf2
check_canceled does not return Result
2019-01-15 15:45:48 +03:00
Aleksey Kladov
dd45697e53
update salsa
2019-01-15 15:06:45 +03:00
bors[bot]
f6f2e89e7a
Merge #546
...
546: replace `assert_dbg_eq` with Insta r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-15 11:18:56 +00:00
Aleksey Kladov
d79a9b17dc
switch to insta for testing
2019-01-15 14:18:24 +03:00
Yerkebulan Tulibergenov
4149285bf5
add semi only if it wasn't present before or after
2019-01-15 01:21:04 -08:00
bors[bot]
e8e82ce032
Merge #485
...
485: Add type inference for a bunch of primitives r=flodiebold a=marcusklaas
This PR adds inference for `&str`, `&[u8]`, `char`, `bool`, floats and integers. For floats and integers it uses type variables to infer the exact type, i.e. `u32`, from context when it's not annotated explicitly.
I'm not quite happy with the implementation yet, but I think it mostly works now.
Co-authored-by: Marcus Klaas de Vries <mail@marcusklaas.nl>
2019-01-14 20:58:20 +00:00
Marcus Klaas de Vries
37ba237e66
Address issues found in review
2019-01-14 21:52:08 +01:00
Marcus Klaas de Vries
d67eabb512
Fix type inference for raw (byte) strings
2019-01-14 20:56:14 +01:00
Marcus Klaas de Vries
2689348772
Give literal expression default values for now
2019-01-14 19:46:10 +01:00
Marcus Klaas de Vries
a9a6a50c75
Fixup tests
2019-01-14 19:30:21 +01:00
Aleksey Kladov
db43b44f71
update cargo_metadata
2019-01-14 16:15:25 +03:00
Marcus Klaas de Vries
606d66a714
Start moving literal interpretation to the AST (WIP)
2019-01-14 13:56:43 +01:00
Marcus Klaas de Vries
81bc8e4973
don't try to treat arrays and tuples as literals
2019-01-14 13:55:49 +01:00
Marcus Klaas de Vries
1574715be5
Use type variables to determine exact type for ambiguous numeric literals
2019-01-14 13:54:31 +01:00
Marcus Klaas de Vries
5f5dc20d85
Try implementing integer type inference (WIP)
2019-01-14 13:52:57 +01:00
Marcus Klaas de Vries
a6146d35b1
Implement type inference for literals (WIP)
2019-01-14 13:52:55 +01:00
Aleksey Kladov
7e5ab9b78c
switch to lsp-types
2019-01-14 14:32:03 +03:00
Yerkebulan Tulibergenov
5d6cf59f60
add semicolon for block expr in introduce_variable
2019-01-13 18:22:53 -08:00
Yerkebulan Tulibergenov
1538ca3ae5
we don't need to write var_name after block expr?
2019-01-13 18:12:01 -08:00
Yerkebulan Tulibergenov
a996b66cc6
add failing test test_introduce_var_block_expr_second_to_last
2019-01-13 17:59:56 -08:00
Jeremy Kolb
da326dca60
Remove duplication
2019-01-13 20:25:14 -05:00
Jeremy Kolb
2d7b4cc548
Add visibility to hover
2019-01-13 20:08:33 -05:00
Aleksey Kladov
5498a202b6
target_selection_range is not nullable in the implementation
2019-01-13 22:42:42 +03:00
bors[bot]
fa6e4b7978
Merge #532
...
532: fix go to parent module r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-13 19:01:06 +00:00
Aleksey Kladov
077a02271c
fix go to parent module
2019-01-13 21:56:20 +03:00
Pascal Hertleif
f97a9921df
Fix some random typos
2019-01-13 19:54:28 +01:00
Aleksey Kladov
eedc08300c
goto defenition works for type-inferred methods
2019-01-13 18:56:57 +03:00
Aleksey Kladov
884ce4a420
fix indent caclulation
2019-01-13 18:21:23 +03:00
bors[bot]
ff09d15124
Merge #520
...
520: Imprement tuple inference r=flodiebold a=h-michael
related #394
I'm sorry I'm late.
I try implementing array inference next.
Co-authored-by: Hirokazu Hata <h.hata.ai.t@gmail.com>
2019-01-13 13:25:33 +00:00
Hirokazu Hata
139da0841d
Fix tuple test case
2019-01-13 22:23:06 +09:00
Pascal Hertleif
7f16f922da
Tweak message shown for query fallback
...
Small tweak for #518
2019-01-13 13:32:52 +01:00
Hirokazu Hata
6e73cc89b6
Implement tuple inference
2019-01-13 21:10:01 +09:00
Hirokazu Hata
6efda8f6ce
Update TUPLE_EXPR grammar
2019-01-13 21:04:03 +09:00
Hirokazu Hata
829f668bd7
Add infer tuple test
2019-01-13 21:04:03 +09:00
bors[bot]
0199572a3d
Merge #517 #518
...
517: gracefully handle cycles in crate graph r=matklad a=matklad
518: Add an explanatory message when we use the Query fallback r=matklad a=DJMcNab
Fixes https://github.com/rust-analyzer/rust-analyzer/issues/269 .
There is no good way to explain it for go_to_def, so I've just fallen back on to_vec.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2019-01-13 10:41:47 +00:00
Aleksey Kladov
77f67ca7e2
gracefully handle cycles in crate graph
...
rust-lang/rust has absolutely weird setup with rustc-workspace-shim,
which leads to real cycles.
2019-01-13 13:39:48 +03:00
bors[bot]
ff3d91bb0c
Merge #519
...
519: support ref-patterns r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-13 10:36:30 +00:00
Aleksey Kladov
8e554ea5fa
support ref-patterns
2019-01-13 13:36:06 +03:00
DJMcNab
a53c5de1fd
Add an explanatory message when we use the Query fallback
2019-01-13 10:31:37 +00:00
bors[bot]
a2659abed8
Merge #513
...
513: Add bench runnable and code lens r=matklad a=kjeremy
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
2019-01-13 07:59:26 +00:00
Jeremy Kolb
ecf9c203ed
Fix typos
2019-01-12 20:40:30 -05:00
Jeremy Kolb
5d273f10cd
Add bench runnable and code lens
2019-01-12 18:40:54 -05:00
bors[bot]
eb931c0d9e
Merge #505
...
505: Inherent methods r=matklad a=flodiebold
This adds resolution, type checking and completion for inherent methods.
The main open question here is the caching, I think. I'm not sure whether we should be caching method resolutions in a more fine grained way (currently we just build a hash map of types -> impl blocks, and iterate through all potential impl blocks when looking for a method).
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2019-01-12 21:18:14 +00:00
Florian Diebold
1ed7fbfc1b
args -> params
2019-01-12 21:58:16 +01:00
Florian Diebold
5db5f5cc1d
Small improvements from review comments
2019-01-12 21:51:56 +01:00
bors[bot]
e56072bfa3
Merge #500
...
500: Code lens support for running tests r=matklad a=kjeremy
Supports running individual and mod tests.
I feel like this kind of abuses the `Runnables` infrastructure but it works. Maybe later on down the line we should introduce a struct that is really just a tuple of binary, arguments, and environment and pass that back to the client instead. `run_single.ts` is just a paired down version of `runnables.ts` and there is duplication because I think run_single will probably change independent of runnables.
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
Co-authored-by: Jeremy Kolb <kjeremy@gmail.com>
2019-01-12 18:56:11 +00:00
Jeremy Kolb
72d48b08fb
Move CargoTargetSpec
and friends to cargo_target_spec module
2019-01-12 13:00:58 -05:00
bors[bot]
8033c81acc
Merge #507
...
507: Fix handling of attributes in positional field lists r=matklad a=DJMcNab
First reported by @max-frai. This allows us to properly handle crates using e.g. `#[Derive(fail)]` with `#[fail(cause)]`, among other cases.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2019-01-12 15:47:48 +00:00
DJMcNab
0b9e462ab0
Fix handling of attributes in positional field lists
2019-01-12 15:42:12 +00:00
DJMcNab
c38432c0bd
Use --force when installing the VSIX.
2019-01-12 15:00:03 +00:00
Florian Diebold
d0bdaa6c00
Complete inherent methods
2019-01-12 15:01:27 +01:00
Florian Diebold
082ef52bcb
Implement basic inherent method resolution
2019-01-12 15:01:19 +01:00
Jeremy Kolb
f42f70b1d5
Switch hover to use MarkupContent
...
MarkedString is deprecated
2019-01-11 21:45:16 -05:00
Florian Diebold
1212e59bee
Fix assertion error in unification (hopefully)
...
Currently, all types that we handle during inference need to be resolved as far
as possible at the time. It's maybe too brittle of an invariant; I need to think
how we can do this better. This should fix #484 though, I hope (if
it's the same case as I managed to reproduce).
2019-01-11 22:59:00 +01:00
Jeremy A. Kolb
faf0037635
Code lens support for running tests
2019-01-11 15:16:55 -05:00
Aleksey Kladov
f60153ee9e
warn louder on mising sysroot
2019-01-11 20:55:56 +02:00
Aleksey Kladov
f193fbcbae
actually produce missing def kinds
2019-01-11 21:02:12 +03:00
Aleksey Kladov
19136cde00
uncopypaste def sources
2019-01-11 20:43:10 +03:00
Aleksey Kladov
0f9c350812
add missing def kinds
2019-01-11 20:28:10 +03:00
Aleksey Kladov
2d3940d0ab
rename TreePtr -> TreeArc
...
This is much clearer about the semantics
2019-01-11 19:59:06 +03:00
bors[bot]
aad1bf877e
Merge #496
...
496: Include two element ranges into the nav. r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-11 15:35:41 +00:00
Aleksey Kladov
f23a13bfa7
kill NavTarget ptr
2019-01-11 18:35:04 +03:00
Aleksey Kladov
dda916bc4d
fix tests
2019-01-11 18:32:22 +03:00
Aleksey Kladov
4089db1e0d
prioritize event handing over indexing
...
If we index gazillion libraries simultaneously, we fill the threadpool
and so the main loop fails to turn, although there isn't really any
significant blocking inside the loop itself.
2019-01-11 17:08:49 +03:00
Aleksey Kladov
8a5f74a24f
use location link in goto def
2019-01-11 16:06:22 +03:00
Aleksey Kladov
3aaf20bd6e
return ref ranges from gotodef
2019-01-11 16:06:08 +03:00
Aleksey Kladov
f9ed8d4d23
envapsulate navigation target better
2019-01-11 16:01:57 +03:00
Aleksey Kladov
1d3d05d5d7
simplify
2019-01-11 16:01:57 +03:00
Aleksey Kladov
a5dd04078e
reshuffle nones
2019-01-11 16:01:57 +03:00
Aleksey Kladov
7b14377965
refactor nav target
2019-01-11 16:01:57 +03:00
Aleksey Kladov
df6bbc6e42
Make from_syntax private
2019-01-11 16:01:57 +03:00
Aleksey Kladov
2aa125251e
move nav to a separate file
2019-01-11 16:01:57 +03:00
Aleksey Kladov
f848aa97ab
group feature modules
2019-01-11 16:01:57 +03:00
Aleksey Kladov
a1b661faec
fine grained on typed tests
2019-01-11 15:48:06 +03:00
Aleksey Kladov
d9e70e3160
fix on-type offset
2019-01-11 15:05:40 +03:00
Aleksey Kladov
4aa632761f
make on dot typed actually work
2019-01-11 14:57:19 +03:00
Aleksey Kladov
66d7adf1cb
force serde in ra_syntax
2019-01-11 13:21:18 +03:00
Aleksey Kladov
4bf6b91b9d
minor
2019-01-11 00:51:34 +03:00
Aleksey Kladov
cd00158b1d
wire sysroot into crate graph
2019-01-11 00:51:34 +03:00
Aleksey Kladov
e35374ec7c
special case std
2019-01-11 00:51:34 +03:00
Aleksey Kladov
8852408bfb
use arena for sysroot
2019-01-11 00:51:34 +03:00
Aleksey Kladov
66fba88534
split module
2019-01-11 00:51:34 +03:00
Aleksey Kladov
e8923713c5
add sysroot boilerplate
2019-01-11 00:51:34 +03:00
bors[bot]
b6bc55f542
Merge #490
...
490: dont depend on tools from lsp-server r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-10 21:46:56 +00:00
Aleksey Kladov
4196b65f21
dont depend on tools from lsp-server
2019-01-11 00:46:32 +03:00
Florian Diebold
a6590ce231
Use name resolution for goto definition
2019-01-10 21:32:54 +01:00
bors[bot]
dc2a8d5acc
Merge #470
...
470: Type inference for enum variants r=flodiebold a=marcusklaas
Opened a new PR instead of https://github.com/rust-analyzer/rust-analyzer/pull/461 . Totally botched that one.
I think I resolved all the issues mentioned there.
Co-authored-by: Marcus Klaas de Vries <mail@marcusklaas.nl>
2019-01-10 19:12:40 +00:00
bors[bot]
a95536301c
Merge #488
...
488: switch CargoWorkspace to arena r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-10 18:59:40 +00:00
Aleksey Kladov
faa1d35cbc
dont complete () if they are already there
2019-01-10 21:38:04 +03:00
Aleksey Kladov
cbeaa541aa
switch CargoWorkspace to arena
2019-01-10 21:26:43 +03:00
DJMcNab
afdb569902
Fix handling of where clauses in tuple structs
2019-01-10 18:21:01 +00:00
Aleksey Kladov
f83485839b
better change visibility assist
...
* don't add visibility before #derive
* suggest changing pub(crate) into pub
2019-01-10 19:18:15 +03:00
bors[bot]
acd90bc33b
Merge #482
...
482: fix code duplication r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-10 15:32:34 +00:00
Aleksey Kladov
a0c978cd0c
fix code duplication
2019-01-10 18:32:02 +03:00
Aleksey Kladov
3ca76c2039
move join_lines to a separate module
2019-01-10 17:50:49 +03:00
Aleksey Kladov
32fa084c07
introduce marking infrastructure for maintainable tests
...
This also fixes a particular edge case in name resolution.
2019-01-10 16:45:09 +03:00
Marcus Klaas de Vries
e78286c8e8
Save variant names in EnumData to reduce needless queries
...
We already have their names when anyway, and when in all (current)
situations where we're interested in an Enum's variants, we want
their names.
2019-01-10 14:43:01 +01:00
Marcus Klaas de Vries
978de5cf8b
Implement type inference for enum variants
2019-01-10 14:32:56 +01:00
bors[bot]
aca14c591f
Merge #475
...
475: Show types of fields in completion r=matklad a=matklad
![image](https://user-images.githubusercontent.com/1711539/50910524-0f146200-143f-11e9-84d6-0ba80761cd89.png )
r? @flodiebold
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-10 13:07:19 +00:00
bors[bot]
aef93c918e
Merge #478
...
478: WIP: implement cancelation via unwinding r=matklad a=matklad
This uses https://github.com/salsa-rs/salsa/pull/107 to implement cancellation.
Now we can get rid of `Cancelable` wrapper from everywhere except the top-level analyzer library.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-10 12:51:58 +00:00
Aleksey Kladov
86bc898a2f
explain why we use resume_unwind
2019-01-10 13:06:42 +03:00
Aleksey Kladov
f72c031eb9
implement RefUnwindSafe
2019-01-10 13:04:04 +03:00
Aleksey Kladov
64455ad701
use unwinding for cancelation
2019-01-10 12:20:32 +03:00
Hrvoje Ban
8384b2cc38
Extend selection for list items
2019-01-09 20:51:19 +01:00
Aleksey Kladov
cf20ecae9f
unwind on cancel
2019-01-09 22:51:05 +03:00
Aleksey Kladov
56b2138d82
show field types in completion
2019-01-09 19:40:11 +03:00
Aleksey Kladov
ddf2a8a948
add completion detail
2019-01-09 19:40:11 +03:00
Aleksey Kladov
e8815b614e
nicer trailing comma handling in types
2019-01-09 19:14:21 +03:00
bors[bot]
76b3985d70
Merge #473
...
473: Partial typo fix r=matklad a=marcusklaas
This fixes some typos. Mostly in documentation, but also some code is affected (`defenition` was used in a few method names).
Co-authored-by: Marcus Klaas de Vries <mail@marcusklaas.nl>
2019-01-09 12:20:05 +00:00
Marcus Klaas de Vries
0b8fbb4fad
Fix typos in ARCHITECTURE.md and a number of crates
...
specifically: gen_lsp_server, ra_arena, ra_cli, ra_db, ra_hir
2019-01-09 01:17:09 +01:00
Aleksey Kladov
d18d8399f5
fuzz-lockfile
2019-01-09 01:58:25 +03:00
Aleksey Kladov
5609989368
more stable DefIds via bfs tree walking
2019-01-09 01:57:40 +03:00
Marcus Klaas de Vries
f8261d611a
Fix typo defenition -> definition
2019-01-08 23:38:51 +01:00
Aleksey Kladov
2dc85619be
one more invalidation test
2019-01-09 00:54:06 +03:00
Aleksey Kladov
bcb6fabd15
fix test naming
2019-01-09 00:49:21 +03:00
Aleksey Kladov
8f93e7b9a4
remove duplication in tests
2019-01-09 00:48:54 +03:00
Aleksey Kladov
0c62b1bb7a
fix the docs
2019-01-08 22:45:52 +03:00
Aleksey Kladov
5b573deb20
fix usages after rename
2019-01-08 22:33:36 +03:00
Aleksey Kladov
6bca91af53
rename ra_analysis -> ra_ide_api
2019-01-08 22:30:56 +03:00
Aleksey Kladov
fa3c9ce392
fix usages after rename
2019-01-08 22:30:32 +03:00
Aleksey Kladov
1967884d68
rename ra_editor -> ra_ide_api_light
2019-01-08 22:17:36 +03:00
Aleksey Kladov
921689b70d
kill text utils
2019-01-08 22:03:13 +03:00
Aleksey Kladov
f553837c1c
upstream text-utils to text_unit
2019-01-08 21:50:04 +03:00
Aleksey Kladov
695294bbb9
ra_db is independent from editor
2019-01-08 21:03:42 +03:00
Aleksey Kladov
0c88360eb4
add comment
2019-01-08 21:01:41 +03:00
Aleksey Kladov
13301f284c
ra_hir does not depend on ra_editor
2019-01-08 21:01:41 +03:00
Aleksey Kladov
702bdacb03
move node at offset to aglo already
2019-01-08 21:01:41 +03:00
Aleksey Kladov
1b82084a5f
dont depend on ra_editor directly
2019-01-08 21:01:41 +03:00
Aleksey Kladov
ac92973a6c
move function to code_model_api
2019-01-08 20:11:13 +03:00
Aleksey Kladov
141ab166cf
switch to newer cargo-metadata
2019-01-08 19:36:09 +03:00
Aleksey Kladov
4fa972cffb
simplify
2019-01-08 18:44:18 +03:00
Aleksey Kladov
6f02f176c8
simplify
2019-01-08 18:43:29 +03:00
Aleksey Kladov
db794abe66
kill FnSignatureInfo
2019-01-08 18:42:11 +03:00
Aleksey Kladov
ed4f13e5c7
remove FnSignatureInfo from hir
2019-01-08 18:38:34 +03:00
Aleksey Kladov
a3f74702d9
move tests
2019-01-08 18:33:19 +03:00
Aleksey Kladov
256ec6e8d4
introduce CallInfo
2019-01-08 18:27:44 +03:00
Aleksey Kladov
e6a4383bb4
move call-info to a separate file
2019-01-08 18:16:26 +03:00
Florian Diebold
946b0ba02c
Fix name resolution across source roots
...
It was using the wrong name in that case.
2019-01-08 15:16:24 +01:00
Florian Diebold
d4b44a092f
Fix use tree desugaring
2019-01-08 15:00:29 +01:00
bors[bot]
562b448f9e
Merge #458
...
458: dont reexport module id r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-08 13:36:13 +00:00
Aleksey Kladov
544c63b58e
dont reexport module id
2019-01-08 16:35:36 +03:00
Aleksey Kladov
821f5186ba
use real signature in completion
2019-01-08 16:08:58 +03:00
Aleksey Kladov
d4c8310d05
switch interner to use arena
2019-01-08 15:53:32 +03:00
Aleksey Kladov
54e5c4f085
minimize visibility
2019-01-08 15:40:02 +03:00
Aleksey Kladov
5edcf313f6
move query impls to adt
2019-01-08 15:38:29 +03:00
Aleksey Kladov
64f202bdd7
move variant public api to api
2019-01-08 15:32:27 +03:00
Aleksey Kladov
2d0ab52212
move variants to API
2019-01-08 15:28:08 +03:00
Aleksey Kladov
71c7936932
minor
2019-01-08 15:23:56 +03:00
Aleksey Kladov
2d4dc22af8
move enum to code_model_api
2019-01-08 15:22:57 +03:00
Aleksey Kladov
e30c533eb6
move stuct to code_model_api
2019-01-08 15:19:37 +03:00
bors[bot]
3bb1cb7017
Merge #455
...
455: Import fixpoint loop for name resolution r=matklad a=flodiebold
This implements reexports, so only the glob import part of #231 remains.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2019-01-08 12:02:06 +00:00
Florian Diebold
dc186c0fcc
Import fixpoint loop for name resolution
2019-01-08 12:53:31 +01:00
Aleksey Kladov
50d5e37481
convert some if-lets to match
2019-01-08 14:23:00 +03:00
Aleksey Kladov
96236a9be5
assist to convert if-let to match
2019-01-08 14:21:29 +03:00
Aleksey Kladov
fa6e0b0d38
itroduce trait for ast tokens
2019-01-08 12:23:10 +03:00
Aleksey Kladov
d62ede8262
migrate ra_lsp_server to new rowan
2019-01-08 11:56:17 +03:00
Aleksey Kladov
3ffd5dd2a6
migrate ra_analysis to new rowan
2019-01-08 11:47:28 +03:00
Aleksey Kladov
da0b348ae9
migrate ra_hir to rowan 2.0
2019-01-08 11:28:42 +03:00
Aleksey Kladov
d6020f516f
migrate ra_cli to new rowan
2019-01-08 11:20:15 +03:00
Aleksey Kladov
fe53b28250
migrate ra_db to new rowan
2019-01-08 11:20:15 +03:00
Aleksey Kladov
b88775af7f
migrate ra_editor to rowan 0.2
2019-01-08 11:20:15 +03:00
Aleksey Kladov
b73c51ff9b
wrap TreePtr
2019-01-08 11:20:15 +03:00
Aleksey Kladov
5618c8ade1
regenerate
2019-01-08 11:20:15 +03:00
Aleksey Kladov
d91a98ec84
switch ra_syntax to new rowan API
2019-01-08 11:20:15 +03:00
Aleksey Kladov
55272f2023
update rowan
2019-01-08 11:20:15 +03:00
Marcus Klaas de Vries
e51d44a2de
Process explicit type hints for str, bool and char
2019-01-07 20:43:41 +01:00
Marcus Klaas de Vries
5d15dd70b0
Tidy up binary operator type inference; add test file
2019-01-07 20:39:23 +01:00
Marcus Klaas de Vries
7b0eaef580
Implement type inference for more binary operators
...
Mostly just for primitive numeric types such as u32 and f64. Not
yet a general solution using trait resolution.
2019-01-07 20:11:31 +01:00
Marcus Klaas de Vries
3238c06a5a
Add remaining binary operations to AST
2019-01-07 19:04:25 +01:00
Florian Diebold
7bb279b365
Implement autoderef for field accesses
2019-01-07 14:54:23 +01:00
bors[bot]
a6071c9f4c
Merge #442
...
442: WIP: indent on typing dot r=matklad a=simonvandel
Fixes #439 .
The unit test passes, but I can't seem to make VS code perform the action. The existing action on "=" doesn't work either on my end either though.
I didn't add any smart way of detecting the current indent level. Any ideas how I would do that?
Co-authored-by: Simon Vandel Sillesen <simon.vandel@gmail.com>
2019-01-07 06:26:09 +00:00
Simon Vandel Sillesen
f3c708ab7b
my formatting tool locally messes things up
2019-01-07 06:24:07 +01:00
Simon Vandel Sillesen
979dcf36e4
fix nits
2019-01-07 06:16:04 +01:00
Florian Diebold
d618b1f2ce
if let -> match
2019-01-07 01:10:29 +01:00
Florian Diebold
2dfb5e6ac0
Improve types for node_expr / node_pat
2019-01-07 00:05:19 +01:00
Florian Diebold
71f7d82e45
Introduce ArenaMap
2019-01-07 00:05:19 +01:00
Florian Diebold
cf49a11263
Sort ranges in type inference tests
...
Also rename the files to remove the numbers (they don't serve a purpose now that
there are only the data files).
2019-01-07 00:05:19 +01:00
Florian Diebold
6210e82041
Use HIR Expr for type inference
...
Now we can reuse the type inference inside a function when typing whitespace
etc. :)
2019-01-07 00:05:19 +01:00
Florian Diebold
a4e97f5a2b
Show types when hovering patterns as well
2019-01-06 22:53:09 +01:00
bors[bot]
31c1999505
Merge #440
...
440: Implement type inference for boolean operators r=flodiebold a=marcusklaas
Tried implementing the easiest part of https://github.com/rust-analyzer/rust-analyzer/issues/390 . Hope this is somewhat close to what the intent of the issue was. Found it surprisingly easy to find my way around the repository - it's well organized!
Very grateful for any pointers.
Co-authored-by: Marcus Klaas de Vries <mail@marcusklaas.nl>
2019-01-06 21:28:36 +00:00
Marcus Klaas de Vries
82d9a77dad
Touch up type inference for boolean operators
...
Also try to infer its subexpressions and set type expectations
whenever possible.
2019-01-06 22:17:54 +01:00
Simon Vandel Sillesen
bbc044990a
formatting
2019-01-06 22:06:22 +01:00
Simon Vandel Sillesen
0be055072d
fix tests
2019-01-06 21:59:14 +01:00
Aleksey Kladov
8a3b489c2f
kill module source
2019-01-06 20:01:26 +03:00
Aleksey Kladov
733383446f
move submodule computationt to module_tree
2019-01-06 17:44:50 +03:00
Aleksey Kladov
17b2994b99
fix the test
2019-01-06 17:38:20 +03:00
Aleksey Kladov
5b0267ecf7
fix after rebase
2019-01-06 17:37:18 +03:00
Aleksey Kladov
fd4456d0ec
flatten module structure
2019-01-06 17:36:10 +03:00
Aleksey Kladov
5a505189a8
adjust comments
2019-01-06 17:35:57 +03:00
Aleksey Kladov
c303e6fbdf
fix ra_analysis to work with the new API
2019-01-06 17:35:57 +03:00
Aleksey Kladov
a7f4f7bfcc
split module source into decl/defin
2019-01-06 17:35:57 +03:00
Aleksey Kladov
9cb02fd931
kill old module
2019-01-06 17:35:57 +03:00
Aleksey Kladov
3c2cb89087
add parent & resolve_path
2019-01-06 17:35:29 +03:00
Aleksey Kladov
1836f4db35
make source cancelable
2019-01-06 17:35:29 +03:00
Aleksey Kladov
b37fba7136
make deps cancelable
2019-01-06 17:35:29 +03:00
Aleksey Kladov
61687b9db6
fix tests
2019-01-06 17:35:29 +03:00
Aleksey Kladov
8c4d277036
switch source-binders to Module
2019-01-06 17:35:29 +03:00
Aleksey Kladov
147b0f94e6
Start code_model::Module
2019-01-06 17:35:29 +03:00
Aleksey Kladov
9a820dc0ee
move crate to code_model_api
2019-01-06 17:35:29 +03:00
bors[bot]
eaf553dade
Merge #441
...
441: hir::Expr r=matklad a=flodiebold
Still a bit to do, but I already adapted `FnScopes` and thought I'd get feedback already.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2019-01-06 13:45:22 +00:00
Simon Vandel Sillesen
4f3bc42349
add more tests
2019-01-06 12:24:33 +01:00
Aleksey Kladov
bc3e732ec5
split_import intention correctly works with use trees
2019-01-06 12:48:33 +03:00
Simon Vandel Sillesen
b0ffa98a00
add "." as a trigger char on type formatting
2019-01-06 09:56:00 +01:00
Simon Vandel Sillesen
2e52b27e71
refactor
2019-01-06 09:41:11 +01:00
Simon Vandel Sillesen
bb8624dff6
format code
2019-01-06 08:08:23 +01:00
Simon Vandel Sillesen
cfaaf33069
rename unused variable
2019-01-06 07:56:02 +01:00
Florian Diebold
98957f4e6f
Add fn signature query
2019-01-06 01:13:31 +01:00
Simon Vandel Sillesen
f99398d9d5
indent on typing dot. fixes #439
2019-01-06 00:58:03 +01:00
Florian Diebold
e5a6cf8153
Various small code review improvements
2019-01-06 00:38:08 +01:00
Florian Diebold
8e3e5ab2c8
Make FnScopes use hir::Expr
...
This was a bit complicated. I've added a wrapper type for now that does the
LocalSyntaxPtr <-> ExprId translation; we might want to get rid of that or give
it a nicer interface.
2019-01-06 00:29:36 +01:00
Florian Diebold
136aba1cf3
Add HIR Expr machinery
2019-01-05 22:41:12 +01:00
Florian Diebold
a6f33b4ca5
Add test for invalidation of inferred types when typing inside function
...
This currently fails, but should work once we have hir::Expr.
2019-01-05 22:41:12 +01:00
Marcus Klaas de Vries
4fc233a02e
Implement type inference for boolean operators
2019-01-05 21:28:30 +01:00
Aleksey Kladov
01cf32c46e
fix tests
2019-01-05 21:09:11 +03:00
Aleksey Kladov
be84a112a7
show types in local variable hovers
2019-01-05 20:53:30 +03:00
Aleksey Kladov
ee461a2111
kill approximatelly_resolve_symbol
2019-01-05 20:00:03 +03:00
Aleksey Kladov
da32463cbf
inline goto_defention tests
2019-01-05 19:41:43 +03:00
Aleksey Kladov
c2a0f5e50f
move goto_defenition to a separate file
2019-01-05 19:30:49 +03:00
Aleksey Kladov
4551155073
introduce separate goto_defenition
2019-01-05 19:30:49 +03:00
Aleksey Kladov
ad2a5da259
kill accidentally added file
2019-01-05 19:30:42 +03:00
Aleksey Kladov
bdbdade036
move typeof to hover
2019-01-05 17:39:34 +03:00
Aleksey Kladov
9f44d4c56d
fold doc_comment into hover
2019-01-05 17:33:31 +03:00
Aleksey Kladov
3ad0037f90
move hover implementation to ra_analysis
2019-01-05 17:24:17 +03:00
Aleksey Kladov
2560a9e807
wip
2019-01-05 16:40:50 +03:00
bors[bot]
8d51b02362
Merge #414
...
414: textDocument/hover returns both type name and doc_text r=matklad a=h-michael
implement #389
Co-authored-by: Hirokazu Hata <h.hata.ai.t@gmail.com>
2019-01-05 13:12:41 +00:00
Aleksey Kladov
79fd6b5c88
change visibility can change pub to pub(crate)
2019-01-05 15:28:07 +03:00
Aleksey Kladov
ea3504057e
split import assist
2019-01-05 13:56:33 +03:00
bors[bot]
481713a0e1
Merge #427
...
427: Remove extra space when joining lines in use items r=matklad a=alanhdu
Fixes #423 .
Co-authored-by: Alan Du <alanhdu@gmail.com>
2019-01-05 07:16:48 +00:00
Alan Du
19c641390d
Fix join_lines use_items right w/ and w/o comma
2019-01-04 22:06:36 -05:00
Alan Du
182ec76f13
Address join lines use items right }
2019-01-04 22:01:11 -05:00
Hirokazu Hata
341eb4ae87
Use both type_of and doc_text_for
2019-01-05 11:28:16 +09:00
bors[bot]
4a3ef8fe63
Merge #370
...
370: Self params & type r=matklad a=flodiebold
This implements type inference for `self`, so field completion for methods taking `self` works now.
- rename `IMPL_ITEM` to `IMPL_BLOCK` -- rustc calls the methods etc. inside an impl `ImplItem`s, and the impl itself doesn't define an item, so I thought this name was clearer.
- add HIR for impl blocks -- we collect all impls in a crate at once, so we can go from methods to containing impls, and since we will later also need to find all impls for a certain type (which may be anywhere in the crate, I think?). We could be more lazy here, but I don't know if it's worth the complexity.
- resolve `self` and `Self` during type inference
- refactor a bit in ty.rs as well
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2019-01-04 19:55:23 +00:00
Aleksey Kladov
6c8e54aaee
⬆️ salsa
2019-01-04 22:31:13 +03:00
Florian Diebold
e6aeabf96f
Rename ImplsInCrateQuery as well
2019-01-04 19:52:07 +01:00
Alan Du
fae8960554
Remove extra space when joining lines in use items
2019-01-04 13:39:43 -05:00
Florian Diebold
443ddb73c3
Do impl collection per module, not per crate
2019-01-04 19:29:53 +01:00
Florian Diebold
334ca0d9a7
Rename ImplBlock::target -> target_type, and add target_trait already
2019-01-04 19:16:39 +01:00
Florian Diebold
bb029cd29b
Rename traits::impl_item -> impl_block as well, as well as the tests
2019-01-04 19:15:15 +01:00
Florian Diebold
0ad13b9477
Add a test for self field completion
...
Needed to add a default crate graph in the analysis for that.
2019-01-04 19:14:52 +01:00
Florian Diebold
6ab0e292d2
Refactor a bit
2019-01-04 19:14:22 +01:00
Florian Diebold
538147bf94
Resolve the Self type
2019-01-04 19:13:50 +01:00
Florian Diebold
d4db61b9a1
Resolve the self parameter during type inference
2019-01-04 19:12:29 +01:00
Florian Diebold
111126ed3c
Type the self parameter
2019-01-04 19:10:50 +01:00
Florian Diebold
ae9530addc
Add HIR for impl blocks
...
Since we need to be able to go from def to containing impl block, as well as the
other direction, and to find all impls for a certain type, a design similar to
the one for modules, where we collect all impls for the whole crate and keep
them in an arena, seemed fitting. The ImplBlock type, which provides the public
interface, then consists only of an Arc to the arena containing all impls, and
the index into it.
2019-01-04 19:10:47 +01:00
Florian Diebold
226e31dae9
Add test for self type inference
2019-01-04 18:28:43 +01:00
Florian Diebold
fe6c4115f6
Rename ImplItem to ImplBlock
...
rustc uses the name ImplItem for items in impls, not the impl {} block itself,
which could lead to confusion.
2019-01-04 18:28:36 +01:00
Aleksey Kladov
3fe6f422f9
remove id arena
2019-01-04 16:58:10 +03:00
Aleksey Kladov
291d578938
extract area to a crate
2019-01-04 16:58:10 +03:00
csmoe
a0ef196d04
add mod doc comments test in ast
2019-01-04 21:51:45 +08:00
csmoe
f604ff5b2f
parse doc comment for items
2019-01-04 21:29:00 +08:00
csmoe
8a6d6ac132
add mod doc comment test
2019-01-04 21:28:09 +08:00
bors[bot]
6295bbe6ec
Merge #391
...
391: docing parser methods r=csmoe a=csmoe
Co-authored-by: csmoe <csmoe@msn.com>
2019-01-04 04:36:40 +00:00
csmoe
58139c558a
consume trivias for type/const def
2019-01-04 12:22:57 +08:00
csmoe
df591a1e48
doc parsing events
2019-01-04 12:21:47 +08:00
Aleksey Kladov
d61707b4e1
index stuff produced by macros
2019-01-03 21:29:17 +03:00
Aleksey Kladov
ebd7c04faa
construct index from symbols directly
2019-01-03 21:29:05 +03:00
Aleksey Kladov
cd32177a25
don't create many compilation units for tests
2019-01-03 20:15:12 +03:00
bors[bot]
8a24f25482
Merge #419
...
419: file-id-to-symbol r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-03 16:56:08 +00:00
Aleksey Kladov
9bb2a74256
embed file_id into FileSymbol
2019-01-03 19:55:34 +03:00
Aleksey Kladov
233b170e83
add pub(crate) works for named fields
2019-01-03 19:37:41 +03:00
bors[bot]
33924c0939
Merge #416
...
416: assist-builder r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-03 16:08:52 +00:00
Aleksey Kladov
6be39ba758
fix the test
2019-01-03 19:08:24 +03:00
Aleksey Kladov
a4635a199b
more enterprisey assists API
2019-01-03 18:59:17 +03:00
Bernardo
7d9e02e5a2
fix tests
2019-01-03 14:43:47 +01:00
Bernardo
3ab328b49a
use lsp WorkspaceEdit instead of custom source_file_edits and file_system_edits
2019-01-03 14:20:15 +01:00
Aleksey Kladov
a5935687cb
split assists over several files
2019-01-03 15:21:49 +03:00
Aleksey Kladov
5323e59996
rename code-actions -> assists
2019-01-03 15:21:31 +03:00
Aleksey Kladov
0a80d9685a
visibility owner
2019-01-03 15:21:31 +03:00
Hirokazu Hata
6ee7788513
Return type name when doc_text_for returns nothing
2019-01-03 21:15:23 +09:00
Aleksey Kladov
3e764f97eb
hardcode vec macro
2019-01-03 14:48:23 +03:00
bors[bot]
d29e98dd97
Merge #409
...
409: Add Analysis#teype_of test r=matklad a=h-michael
Co-authored-by: Hirokazu Hata <h.hata.ai.t@gmail.com>
2019-01-03 10:06:32 +00:00
Hirokazu Hata
4363e7b9b2
Deive type_of test from tests
2019-01-03 19:04:42 +09:00
Aleksey Kladov
8d61853509
docs
2019-01-03 12:57:30 +03:00
Hirokazu Hata
f99e96698c
Remove unnecessary mock functions
2019-01-03 18:27:02 +09:00
Aleksey Kladov
03ea6bcbff
use LocalPtr in navigation target
2019-01-03 12:26:40 +03:00
Aleksey Kladov
267a89bca2
use LocalSyntaxPtr for file symbol
2019-01-03 12:26:40 +03:00
Aleksey Kladov
f534d2132b
move some logic to navigation target
2019-01-03 12:26:40 +03:00
Aleksey Kladov
80a91e6735
add kind to LocalSyntaxPtr
2019-01-03 12:26:40 +03:00
Aleksey Kladov
f673529a33
explain that completion shouldn't do filtering
2019-01-03 12:23:15 +03:00
Hirokazu Hata
f5992964ed
Add Analysis#teype_of test
2019-01-03 12:07:20 +09:00
bors[bot]
54efd8204e
Merge #407
...
407: run r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-02 17:13:06 +00:00
Aleksey Kladov
28f6eedba5
simplify runnables
2019-01-02 20:12:38 +03:00
bors[bot]
4f30c45933
Merge #406
...
406: Simplify r=matklad a=matklad
Get rid of `AnalysisImpl` wrapper around salsa database. It was useful before we migrated by salsa, but it's long have been just a useless boilerplate.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-02 16:42:29 +00:00
Aleksey Kladov
ef08b6c084
fix compilation
2019-01-02 19:41:57 +03:00
Aleksey Kladov
5d483cb998
doctrings
2019-01-02 19:40:41 +03:00
Aleksey Kladov
08d1537468
get rid of AnalysisImpl
2019-01-02 19:20:56 +03:00
gfreezy
9672ae001e
extend selection inside a string literal should select a word first
2019-01-02 23:42:38 +08:00
Aleksey Kladov
e9b47dbb36
remove AnalysisHostImpl
2019-01-02 18:41:41 +03:00
Aleksey Kladov
2f22c861a9
remove some methods from analysis impl
2019-01-02 18:11:49 +03:00
Aleksey Kladov
a94530afb3
move world-symbols to file_symbols
2019-01-02 18:08:14 +03:00
bors[bot]
29d8bfb9c9
Merge #404
...
404: Move FileSymbol to ra_analysis r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-01-02 14:26:06 +00:00
Aleksey Kladov
76910639e6
fix tests
2019-01-02 17:25:28 +03:00
Aleksey Kladov
fb775a293d
make FileSymbol private
2019-01-02 17:11:04 +03:00
Aleksey Kladov
830abe0c1b
use navigation target in API
2019-01-02 17:09:39 +03:00
Aleksey Kladov
d25c89f760
introduce navigation target
2019-01-02 16:53:40 +03:00
Aleksey Kladov
a4b4fd7dc5
move symbols to ra_analysis
2019-01-02 16:29:08 +03:00
Aleksey Kladov
1076e82856
small rename
2019-01-02 16:00:35 +03:00
Aleksey Kladov
35b3fc02e0
comments
2019-01-02 16:00:01 +03:00
Aleksey Kladov
4fe0ec5497
rename
2019-01-02 12:49:47 +03:00
Aleksey Kladov
db8d293208
move macro id to ids
2019-01-02 00:37:36 +03:00
Aleksey Kladov
42cc77703b
move more stuff to ids
2019-01-02 00:30:00 +03:00
Aleksey Kladov
37ed2f35ba
rename MFileId -> HirFileId
2019-01-02 00:09:54 +03:00
Aleksey Kladov
9c65e61849
introduce ids module
2019-01-01 22:47:10 +03:00
Aleksey Kladov
fca1422ea3
add tests for macro generated items
2019-01-01 22:15:35 +03:00
Aleksey Kladov
756e878158
add items from macros to modules
2019-01-01 22:15:35 +03:00
Aleksey Kladov
4a3f76d3bb
wip
2019-01-01 22:15:35 +03:00
Aleksey Kladov
f8d419ee89
fix tests
2019-01-01 22:15:35 +03:00
Aleksey Kladov
289391e163
use MFile
2019-01-01 22:15:35 +03:00
Aleksey Kladov
4161466918
introduce MFileId
2019-01-01 22:15:35 +03:00
Aleksey Kladov
9d4af40995
work towards brining macros to nameres
2019-01-01 22:15:35 +03:00
Aleksey Kladov
7dc45745a3
save top-level macros in module items
2019-01-01 22:15:35 +03:00
Aleksey Kladov
e5b2fd6771
hard-code expansion of query_group
2019-01-01 22:15:35 +03:00
Aleksey Kladov
832bae8e28
fix tests
2019-01-01 22:15:35 +03:00
Aleksey Kladov
882a86240f
rename
2019-01-01 22:15:35 +03:00
Aleksey Kladov
b2fec18098
move more macros to hir
2019-01-01 22:15:35 +03:00
Aleksey Kladov
57030f587b
use macros database in analysis
2019-01-01 22:15:35 +03:00
Aleksey Kladov
d753656192
introduce MacrosDatabase
2019-01-01 22:15:35 +03:00
gfreezy
39dab68404
place complete_use_tree_keyword in the same mod with complete_expr_keyword
2019-01-01 23:12:51 +08:00
gfreezy
9895529d5c
move to a seperate complete_use_tree_keyword mod
2019-01-01 23:00:29 +08:00
gfreezy
22ea00d5ff
complete "self" and "super"
2019-01-01 22:45:53 +08:00
gfreezy
f408b1caa3
complete "use crate" for "use cr" too
2019-01-01 22:10:11 +08:00
gfreezy
fc2d7d1e1f
complete crate in use stmt
2019-01-01 21:55:27 +08:00
Aleksey Kladov
acc38a9737
bump deps
2019-01-01 16:21:50 +03:00
DJMcNab
0ddeb3b824
Fix the same bug as #396 but for bytes too
2019-01-01 12:10:21 +00:00
bors[bot]
5a866a772c
Merge #396
...
396: Fix the `panic` found whilst fuzzing r=matklad,me a=DJMcNab
This occurred when a non-ascii character was used in an ascii escape, for example in the motivating example: `if'\xɿ`, which can be further simplified to `'\xɿ`.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2019-01-01 11:11:20 +00:00
DJMcNab
0fd87cbc47
Use an else if
2019-01-01 11:10:08 +00:00
csmoe
b01e707dba
doc parser input
2019-01-01 16:09:32 +08:00
DJMcNab
72ab6f7727
Fix the panic
found whilst fuzzing
2018-12-31 23:02:04 +00:00
bors[bot]
6044ec5057
Merge #395
...
395: generalize r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-31 16:06:27 +00:00
Aleksey Kladov
862c99d0d5
generalize highlighting to work with nodes
2018-12-31 19:06:00 +03:00
Aleksey Kladov
f1e8ebfbeb
generalize extend selection to work with nodes
2018-12-31 19:01:51 +03:00
bors[bot]
2a65020442
Merge #165
...
165: Make modules with tests runnable r=farodin91 a=farodin91
Fixes #154
I having problems to traverse the path to module. The main problem is that module_tree only supports `FileId` and not `Module` in files. Any idea?
I need to clean up the code a bit later.
Co-authored-by: Jan Jansen <farodin91@googlemail.com>
2018-12-31 14:15:34 +00:00
Jan Jansen
05daa86634
Make modules with tests runnable
...
Fixes #154
2018-12-31 15:00:04 +01:00
bors[bot]
700b334a28
Merge #393
...
393: Add a fuzzing subcommand r=matklad a=DJMcNab
Part of https://github.com/rust-analyzer/rust-analyzer/issues/61#issuecomment-450641045 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-31 13:16:09 +00:00
DJMcNab
f61830d676
Add a fuzzing subcommand
2018-12-31 13:14:06 +00:00
Aleksey Kladov
a3ee07ac14
fix icons in completion
2018-12-31 16:06:14 +03:00
csmoe
ea7b569e1b
docing parser methods
2018-12-31 21:00:05 +08:00
bors[bot]
2746dacac0
Merge #385
...
385: Implement DocumentHighlight r=matklad a=DJMcNab
Fixes #80 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-31 12:37:05 +00:00
DJMcNab
be75e547ce
Use TryConv for conversion
2018-12-31 12:17:05 +00:00
DJMcNab
79941a9e70
Implement DocumentHighlight
2018-12-31 11:08:44 +00:00
dependabot[bot]
96ecd73a5c
Bump serde_json from 1.0.33 to 1.0.34
...
Bumps [serde_json](https://github.com/serde-rs/json ) from 1.0.33 to 1.0.34.
- [Release notes](https://github.com/serde-rs/json/releases )
- [Commits](https://github.com/serde-rs/json/compare/v1.0.33...v1.0.34 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-31 09:48:16 +00:00
dependabot[bot]
51ce71686a
Bump failure from 0.1.3 to 0.1.4
...
Bumps [failure](https://github.com/rust-lang-nursery/failure ) from 0.1.3 to 0.1.4.
- [Release notes](https://github.com/rust-lang-nursery/failure/releases )
- [Changelog](https://github.com/rust-lang-nursery/failure/blob/master/RELEASES.md )
- [Commits](https://github.com/rust-lang-nursery/failure/compare/0.1.3...0.1.4 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-31 08:53:49 +00:00
dependabot[bot]
2d9428b54a
Bump failure_derive from 0.1.3 to 0.1.4
...
Bumps [failure_derive](https://github.com/withoutboats/failure_derive ) from 0.1.3 to 0.1.4.
- [Release notes](https://github.com/withoutboats/failure_derive/releases )
- [Commits](https://github.com/withoutboats/failure_derive/commits )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-31 05:36:03 +00:00
Aleksey Kladov
0a8d085619
remove backtraces from Cancelled
...
Hopefully we won't need them for debugging. If we do need them, it
should be easy to add back.
2018-12-31 00:38:50 +03:00
bors[bot]
acc61cc284
Merge #375
...
375: Move renames into ra_analysis and rename the correct range r=DJMcNab a=DJMcNab
Fixes #230 . Supersedes #235 .
TODO: add some tests for this
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-30 20:43:58 +00:00
DJMcNab
872950bc18
Test renames
2018-12-30 20:43:30 +00:00
bors[bot]
f9b58454a4
Merge #378
...
378: migrate-to-tempdir r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-30 20:33:32 +00:00
Aleksey Kladov
f0edb93df2
⬆️ tempdir
2018-12-30 23:33:04 +03:00
bors[bot]
45e3de8eed
Merge #377
...
377: update crossbeam r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-30 20:24:48 +00:00
Aleksey Kladov
c2c10b9014
⬆️ crossbeam
...
closes #189
2018-12-30 23:23:31 +03:00
Aleksey Kladov
effc1eae8b
migrate gen-lsp-server to new crossbeam
2018-12-30 23:02:26 +03:00
Aleksey Kladov
29a52f8d56
refine semi completion
2018-12-30 22:14:35 +03:00
DJMcNab
c402b007a3
Move renames into ra_analysis
2018-12-30 18:14:55 +00:00
bors[bot]
c0d1b17a4e
Merge #366
...
366: parse minus before number literal pattern r=matklad a=csmoe
r?@matklad
![unknown](https://user-images.githubusercontent.com/35686186/50547871-d5449e00-0c7d-11e9-9ff5-1031e78019de.png )
Co-authored-by: csmoe <csmoe@msn.com>
2018-12-30 16:40:16 +00:00
bors[bot]
942c45a31c
Merge #374
...
374: add semi after break&continue r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-30 16:25:30 +00:00
csmoe
53c94e3ad8
parse minus before number literal
2018-12-30 23:25:07 +08:00
Aleksey Kladov
822abb3e62
semies after break&continue
2018-12-30 18:08:17 +03:00
bors[bot]
0f95d8523e
Merge #365
...
365: implement struct shorthand initialization diagnostic r=matklad a=gfreezy
Co-authored-by: gfreezy <gfreezy@gmail.com>
2018-12-30 15:07:27 +00:00
gfreezy
e1ef205a19
avoid allocating an unnecessary intermediate vector & not traverse multiple times
2018-12-30 23:03:43 +08:00
gfreezy
a3520bf01d
implement struct shorthand initialization diagnostic
2018-12-30 22:26:59 +08:00
Aleksey Kladov
0f75ac1ae0
add ;
to last return in block
2018-12-30 17:22:12 +03:00
Aleksey Kladov
c182aab546
don't add () in use items
2018-12-30 16:29:10 +03:00
Aleksey Kladov
3ee7a95315
use completion context when creating completion
2018-12-30 16:20:17 +03:00
Aleksey Kladov
0e90e0436a
remove runtime dependency on tools
2018-12-30 15:28:54 +03:00
bors[bot]
8d1df9834c
Merge #358
...
358: Add support for formatting entire document with rustfmt r=matklad a=aleksanb
Attempting to format a document when rustfmt isn't installed will result
in an error being returned to the frontend. An alternative
implementation would be returning zero replacements.
Part of https://github.com/rust-analyzer/rust-analyzer/issues/160 .
Co-authored-by: Aleksander Vognild Burkow <aleksanderburkow@gmail.com>
2018-12-30 10:16:22 +00:00
Aleksey Kladov
1ac934eafa
add paramthesis when completing functions
2018-12-30 12:49:07 +03:00
Aleksander Vognild Burkow
0cb270e75d
Simplify failure bail code
2018-12-30 00:21:15 +01:00
DJMcNab
5dd602f901
Reuse has_rs_extension in io.rs
2018-12-29 22:45:01 +00:00
Aleksander Vognild Burkow
ed47c93afe
Install rustfmt in rustfmt test
2018-12-29 23:38:26 +01:00
Aleksander Vognild Burkow
09c20c8fcf
Add better error message for Command failure
2018-12-29 23:38:26 +01:00
DJMcNab
07202f944c
Remove some unnecessary unwraps by using the Result::ok
...
combinatoric
2018-12-29 22:33:28 +00:00
DJMcNab
c881fc607e
Fix instance of uneeded brackets in use_statement (thanks to #333 )
2018-12-29 22:32:39 +00:00
DJMcNab
f18e25f24c
Improve comment contents
2018-12-29 22:30:54 +00:00
DJMcNab
764ddc0c85
Fix a switched line in a comment
2018-12-29 22:07:56 +00:00
Aleksander Vognild Burkow
8b24f158f7
Add support for formatting entire document with rustfmt
...
Attempting to format a document when rustfmt isn't installed will result
in an error being returned to the frontend. An alternative
implementation would be returning zero replacements.
2018-12-29 21:57:46 +01:00
Florian Diebold
4142792d1f
Add more docs in ty.rs
...
Also get rid of the indirection through query_definitions for the type-related
queries.
2018-12-29 20:27:13 +01:00
bors[bot]
4a3d6aa26a
Merge #356
...
356: Fix a bug in char literal validation discovered through fuzzing r=matklad a=DJMcNab
We also add a Cargo.lock to the fuzzing directory, as that isn't gitignored automatically, so I imagine it should be committed.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-29 12:50:34 +00:00
DJMcNab
b67a4e7a57
Add fuzz failure to the fuzz-failures directory
2018-12-29 12:45:48 +00:00
DJMcNab
054f22f231
Fix a fuzzing bug and add Cargo.lock to the fuzzing directory
2018-12-29 12:40:08 +00:00
Florian Diebold
b1590bdf6a
Missing return type means unit, not unknown
2018-12-29 12:08:57 +01:00
Florian Diebold
cfa1de72eb
Implement type variables
...
This will really become necessary when we implement generics, but even now, it
allows us to reason 'backwards' to infer types of expressions that we didn't
understand for some reason.
We use ena, the union-find implementation extracted from rustc, to keep track of
type variables.
2018-12-29 12:04:34 +01:00
Aleksey Kladov
7928995876
nameify structs&enums
2018-12-28 21:34:58 +03:00
Aleksey Kladov
11122e29b7
completion for enum variants
2018-12-28 21:07:47 +03:00
Aleksey Kladov
1a860dba38
simplify
2018-12-28 20:45:58 +03:00
Aleksey Kladov
5299a35e3d
extend selection works with macros
2018-12-28 20:33:39 +03:00
bors[bot]
7a268b9b96
Merge #350
...
350: Super simple macro support r=matklad a=matklad
Super simple support for macros, mostly for figuring out how to fit them into the current architecture. Expansion is hard-coded and string based (mid-term, we should try to copy-paste macro-by-example expander from rustc).
Ideally, we should handle
* highlighting inside the macro (done)
* extend selection inside the macro
* completion inside the macro
* indexing structs, produced by the macro
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-28 16:17:19 +00:00
Aleksey Kladov
13631a2955
⬆️ salsa
2018-12-28 19:10:31 +03:00
Aleksey Kladov
b911ee542b
move macro to a separate module
2018-12-28 18:21:30 +03:00
Aleksey Kladov
fd33c89207
switch to FileRange
2018-12-28 18:17:43 +03:00
Aleksey Kladov
02924174bb
introduce FileRange
2018-12-28 18:17:43 +03:00
Aleksey Kladov
d7440a5f49
highlight macro idents
2018-12-28 18:17:43 +03:00
Aleksey Kladov
406505e096
super simplistic macro expansion
2018-12-28 16:59:58 +03:00
Aleksey Kladov
072028e679
add macro-call node
2018-12-28 13:27:30 +03:00
Aleksey Kladov
dc496d0516
move highlightning to a separate file
2018-12-28 13:14:39 +03:00
dependabot[bot]
626badc30a
Bump serde from 1.0.82 to 1.0.83
...
Bumps [serde](https://github.com/serde-rs/serde ) from 1.0.82 to 1.0.83.
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.82...v1.0.83 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-28 06:08:30 +00:00
Aleksey Kladov
bc833216d7
simplify
2018-12-28 00:08:33 +03:00
Aleksey Kladov
58a631f39a
dead code
2018-12-28 00:01:56 +03:00
Aleksey Kladov
dddbac6877
remove FnId
2018-12-27 23:51:44 +03:00
Aleksey Kladov
e066050671
use names everywhere
2018-12-27 21:21:10 +03:00
Aleksey Kladov
63f54d234f
dont leak Name details in testing
2018-12-27 21:02:08 +03:00
Aleksey Kladov
a9f55029b9
introduce known names
2018-12-27 20:26:15 +03:00
Aleksey Kladov
d963042ca9
introduce hir::Name
2018-12-27 20:07:21 +03:00
Aleksey Kladov
e4de2c8d7f
add function to completion ctx
2018-12-27 17:33:52 +03:00
bors[bot]
7a1ed6400d
Merge #341
...
341: Bump languageserver-types from 0.53.0 to 0.53.1 r=matklad a=dependabot[bot]
Bumps [languageserver-types](https://github.com/gluon-lang/languageserver-types ) from 0.53.0 to 0.53.1.
<details>
<summary>Commits</summary>
- [`1a6c6c1`](1a6c6c18fc
) (cargo-release) version 0.53.1
- [`5591192`](5591192047
) Merge pull request [#88 ](https://github-redirect.dependabot.com/gluon-lang/languageserver-types/issues/88 ) from Xanewok/hover-clone
- [`c78120b`](c78120bf28
) Add `Clone` impl for HoverContents and related
- See full diff in [compare view](https://github.com/gluon-lang/languageserver-types/compare/v0.53.0...v0.53.1 )
</details>
<br />
[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=languageserver-types&package-manager=cargo&previous-version=0.53.0&new-version=0.53.1 )](https://dependabot.com/compatibility-score.html?dependency-name=languageserver-types&package-manager=cargo&previous-version=0.53.0&new-version=0.53.1 )
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
**Note:** This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit.
You can always request more updates by clicking `Bump now` in your [Dependabot dashboard](https://app.dependabot.com ).
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme
Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com ):
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)
Finally, you can contact us by mentioning @dependabot.
</details>
Co-authored-by: dependabot[bot] <support@dependabot.com>
2018-12-27 13:38:15 +00:00
dependabot[bot]
74f342648d
Bump languageserver-types from 0.53.0 to 0.53.1
...
Bumps [languageserver-types](https://github.com/gluon-lang/languageserver-types ) from 0.53.0 to 0.53.1.
- [Release notes](https://github.com/gluon-lang/languageserver-types/releases )
- [Changelog](https://github.com/gluon-lang/languageserver-types/blob/master/release.toml )
- [Commits](https://github.com/gluon-lang/languageserver-types/compare/v0.53.0...v0.53.1 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-27 13:15:04 +00:00
dependabot[bot]
4017966a0b
Bump parking_lot from 0.6.4 to 0.7.0
...
Bumps [parking_lot](https://github.com/Amanieu/parking_lot ) from 0.6.4 to 0.7.0.
- [Release notes](https://github.com/Amanieu/parking_lot/releases )
- [Changelog](https://github.com/Amanieu/parking_lot/blob/master/CHANGELOG.md )
- [Commits](https://github.com/Amanieu/parking_lot/commits )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-27 13:14:24 +00:00
bors[bot]
d8bfad9e92
Merge #343 #344
...
343: Bump arrayvec from 0.4.9 to 0.4.10 r=matklad a=dependabot[bot]
Bumps [arrayvec](https://github.com/bluss/arrayvec ) from 0.4.9 to 0.4.10.
<details>
<summary>Commits</summary>
- [`21661fa`](21661facf8
) 0.4.10
- [`06930d2`](06930d27ce
) FIX: Remove unused Copy/Clone for MaybeUninit
- [`85d9a06`](85d9a06a62
) FIX: Use repr(C) MaybeUninit after discussion with RalfJung
- See full diff in [compare view](https://github.com/bluss/arrayvec/compare/0.4.9...0.4.10 )
</details>
<br />
[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=arrayvec&package-manager=cargo&previous-version=0.4.9&new-version=0.4.10 )](https://dependabot.com/compatibility-score.html?dependency-name=arrayvec&package-manager=cargo&previous-version=0.4.9&new-version=0.4.10 )
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
**Note:** This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit.
You can always request more updates by clicking `Bump now` in your [Dependabot dashboard](https://app.dependabot.com ).
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme
Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com ):
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)
Finally, you can contact us by mentioning @dependabot.
</details>
344: Bump itertools from 0.7.11 to 0.8.0 r=matklad a=dependabot[bot]
Bumps [itertools](https://github.com/bluss/rust-itertools ) from 0.7.11 to 0.8.0.
<details>
<summary>Commits</summary>
- [`cd0602a`](cd0602addc
) 0.8.0
- [`5a8f2fd`](5a8f2fd5ed
) MAINT: Require Rust 1.24 as minimum version
- [`4986d92`](4986d92d7f
) DOC: Minor edits to module docs
- [`01f15a0`](01f15a0910
) Merge [#288 ](https://github-redirect.dependabot.com/bluss/rust-itertools/issues/288 )
- [`883d40a`](883d40a6ef
) map_into method
- [`3bf265d`](3bf265d5b7
) Merge pull request [#321 ](https://github-redirect.dependabot.com/bluss/rust-itertools/issues/321 ) from JohnHeitmann/master
- [`e820996`](e820996f64
) Document the trait extension behavior of Itertools a bit more clearly
- [`44c9654`](44c9654fdb
) Merge pull request [#318 ](https://github-redirect.dependabot.com/bluss/rust-itertools/issues/318 ) from bluss/std-deprecations
- [`d2e254f`](d2e254f22f
) API: Fix the mystery deprecation message for Step
- [`602f2f6`](602f2f675e
) API: Deprecate .foreach() in favour of std's .for_each()
- Additional commits viewable in [compare view](https://github.com/bluss/rust-itertools/compare/0.7.11...0.8.0 )
</details>
<br />
[![Dependabot compatibility score](https://api.dependabot.com/badges/compatibility_score?dependency-name=itertools&package-manager=cargo&previous-version=0.7.11&new-version=0.8.0 )](https://dependabot.com/compatibility-score.html?dependency-name=itertools&package-manager=cargo&previous-version=0.7.11&new-version=0.8.0 )
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
**Note:** This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit.
You can always request more updates by clicking `Bump now` in your [Dependabot dashboard](https://app.dependabot.com ).
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme
Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com ):
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)
Finally, you can contact us by mentioning @dependabot.
</details>
Co-authored-by: dependabot[bot] <support@dependabot.com>
2018-12-27 13:06:30 +00:00
dependabot[bot]
a400444e33
Bump itertools from 0.7.11 to 0.8.0
...
Bumps [itertools](https://github.com/bluss/rust-itertools ) from 0.7.11 to 0.8.0.
- [Release notes](https://github.com/bluss/rust-itertools/releases )
- [Commits](https://github.com/bluss/rust-itertools/compare/0.7.11...0.8.0 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-27 12:32:23 +00:00
dependabot[bot]
6fb53caea5
Bump arrayvec from 0.4.9 to 0.4.10
...
Bumps [arrayvec](https://github.com/bluss/arrayvec ) from 0.4.9 to 0.4.10.
- [Release notes](https://github.com/bluss/arrayvec/releases )
- [Commits](https://github.com/bluss/arrayvec/compare/0.4.9...0.4.10 )
Signed-off-by: dependabot[bot] <support@dependabot.com>
2018-12-27 12:32:18 +00:00
bors[bot]
e422c2e2f4
Merge #325
...
325: implement translate_offset_with_edit r=matklad a=vemoo
- Implement `translate_offset_with_edit` to resolve #105
- Add proptest impls for text, offsets and edits and use them in tests for `translate_offset_with_edit` and `LineIndex`
- Added benchmark for `translate_offset_with_edit`
Co-authored-by: Bernardo <berublan@gmail.com>
2018-12-27 12:19:19 +00:00
Aleksey Kladov
49b0fe20ab
fix suffix ranges
2018-12-27 15:10:30 +03:00
Aleksey Kladov
a912b261d3
dump validation errors
2018-12-27 15:07:51 +03:00
Aleksey Kladov
359e70d1b2
support literal suffixes
2018-12-27 15:03:18 +03:00
Aleksey Kladov
73ded3c63c
dedupe literal parsers
2018-12-27 14:42:46 +03:00
Aleksey Kladov
8c2c1bf9eb
check edits in diagnostics
2018-12-27 13:35:08 +03:00
bors[bot]
1d6dcef5c5
Merge #332
...
332: Struct types r=matklad a=flodiebold
Infer types for struct fields, and add basic field completions. There's also some code for enums, but I focused on getting structs working.
There's still ways to go before this becomes useful: There's no autoderef (or even reference types) and no inference for `self`, for example.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2018-12-27 10:08:34 +00:00
Aleksey Kladov
93996fecdc
add cancelation module & cancelation backtraces
2018-12-27 13:03:32 +03:00
Aleksey Kladov
62c40b0e91
fix the test
2018-12-27 12:54:59 +03:00
Aleksey Kladov
4e2dffd798
expose make_pub_crate action
2018-12-27 12:35:40 +03:00
gfreezy
cd60998b9b
fix use std::{self}
2018-12-27 00:51:27 +08:00
Florian Diebold
bc745a1396
Resolve field types lazily
...
I.e. not already when getting the HIR for the struct.
2018-12-25 21:40:33 +01:00
Bernardo
1cda43aafd
test code and dependency cleanup
2018-12-25 21:26:36 +01:00
Florian Diebold
cdca397061
Add a hir::TypeRef as an intermediate between ast::TypeRef and ty::Ty
2018-12-25 21:14:13 +01:00
Bernardo
e9c186e48a
change to TextEdit
to avoid allocation and sort
...
rename newline to step where applicable
2018-12-25 20:49:18 +01:00
Florian Diebold
2870effd5c
Implement reference / pointer types
...
- parse them
- infer types of & and * expressions
2018-12-25 20:36:06 +01:00
Bernardo
863ed19946
remove benchmark and simplify tests
2018-12-25 20:14:27 +01:00
Bernardo
6b2da4e547
use new translate_offset_with_edit for TryConvWith
...
doc comments
2018-12-25 20:06:49 +01:00
Bernardo
aff0124b37
add line_index proptest
2018-12-25 20:03:14 +01:00
Bernardo
c886b72dab
make criterion args work, small simplification
2018-12-25 20:03:14 +01:00
Bernardo
dc2afae991
fix arbitrary offset generation, col translation working
2018-12-25 20:03:14 +01:00
Bernardo
5c8525ce4a
column translation implemented but not quite working yet
2018-12-25 20:03:14 +01:00
Bernardo
36f2b1f3b9
iterate over Step
s which are either, newlines or multibyte chars
2018-12-25 20:03:14 +01:00
Bernardo
1c44ba0f04
simplify newline check with macro
2018-12-25 20:03:14 +01:00
Bernardo
d6312085a1
remove slower impl, add benchmarks
2018-12-25 20:03:14 +01:00
Bernardo
a005d2a614
final iteration, faster a bit simpler
...
the main thing is we iterate over inserted newlines at once for each edit
2018-12-25 19:59:02 +01:00
Bernardo
7299df8409
simplified version
2018-12-25 19:59:02 +01:00
Bernardo
8c9df62c1c
move translate_offset_with_edit to ra_editor
2018-12-25 19:59:02 +01:00
Bernardo
881c29192d
initial newline translation working
...
todo:
cleanup, simplify
handle columns
2018-12-25 19:55:05 +01:00
Bernardo
d951979159
test translate_offset_with_edit against simple impl for single edits
2018-12-25 19:49:55 +01:00
Bernardo
dee426e1b1
simplify and reduce number of values explored
2018-12-25 19:45:21 +01:00
Bernardo
3d98744c2a
proptest strategies for TextUnit and AtomTextEdit
2018-12-25 19:45:21 +01:00
gfreezy
16996e9947
fix tests
2018-12-26 01:00:27 +08:00
Florian Diebold
b96d361239
Handle structs/enums with missing names a bit better
2018-12-25 17:55:50 +01:00
gfreezy
72eb9de747
add fix for removing unnecessary braces in use statements
2018-12-26 00:45:13 +08:00
Florian Diebold
3e4d41d1e4
Determine receiver for completion in a more robust way
...
Also rename a parameter.
2018-12-25 17:43:58 +01:00
Florian Diebold
3befd1a9e8
Cleanup
2018-12-25 15:44:10 +01:00
Florian Diebold
e5a8089b08
Add . to trigger characters
2018-12-25 15:27:15 +01:00
Florian Diebold
ab0b63992b
Implement basic completion for fields
2018-12-25 15:27:15 +01:00
Florian Diebold
0d724ea572
Improve parsing of incomplete field accesses in preparation for field completion
...
We need to be able to get the receiver even if there is no field name yet, and
currently "a." wouldn't get parsed as a field name at all. This seems to help.
2018-12-25 15:16:42 +01:00
Florian Diebold
55c941cd9f
Type field accesses
2018-12-25 15:16:42 +01:00
Florian Diebold
07a7285965
Collect field data for structs/enum variants
2018-12-25 15:16:42 +01:00
Florian Diebold
4cb7b0f2af
Add AST definitions for struct/variant fields etc.
...
Fixes #117
2018-12-25 15:16:42 +01:00
Florian Diebold
6fcd38cc81
Infer result of struct literals, and recurse into their child expressions
2018-12-25 15:16:42 +01:00
Florian Diebold
4ff1618520
Do name resolution by namespace (types/values)
2018-12-25 15:16:42 +01:00
Florian Diebold
b5b68f2094
Add basic HIR and types for structs/enums
2018-12-25 15:16:42 +01:00
Aleksey Kladov
8d49c098a5
cancelled is not Copy
2018-12-25 13:36:39 +03:00
Aleksey Kladov
21293d0533
fix warning conversion
2018-12-25 02:07:30 +03:00
bors[bot]
b65ba8f1d6
Merge #326
...
326: resolved #324 : remove unnecessary braces in use statement. r=matklad a=gfreezy
Add inspection for unnecessary braces in use statement
Co-authored-by: gfreezy <gfreezy@gmail.com>
2018-12-24 18:39:31 +00:00
gfreezy
0fb8894fbe
fix tests
2018-12-24 23:01:16 +08:00
gfreezy
29798c763c
remove option from Diagnostic
2018-12-24 23:00:18 +08:00
gfreezy
70df097c89
keep severity to Error & WeakWarning
2018-12-24 22:48:46 +08:00
bors[bot]
67e768466f
Merge #327
...
327: Beginnings of type inference r=flodiebold a=flodiebold
I was a bit bored, so I thought I'd try to start implementing the type system and see how far I come 😉 This is obviously still extremely WIP, only very basic stuff working, but I thought I'd post this now to get some feedback as to whether this approach makes sense at all.
There's no user-visible effect yet, but the type inference has tests similar to the ones for the parser. My next step will probably be to implement struct types, after which this could probably be used to complete fields.
I realize this may all get thrown away when/if the compiler query system gets usable, but I feel like there are lots of IDE features that could be implemented with somewhat working type inference in the meantime 😄
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2018-12-24 14:40:11 +00:00
Florian Diebold
4befde1eee
Change inference tests to have one per file
2018-12-24 15:36:54 +01:00
Florian Diebold
655f5bc261
Rename a variable for consistency
2018-12-24 15:19:49 +01:00
Florian Diebold
76fb05d91d
Clean up Ty a bit
...
Removing irrelevant comments copied from rustc etc.
2018-12-24 15:18:37 +01:00
bors[bot]
abe09eb5ed
Merge #278
...
278: Add make_pub_crate code action to ra_editor r=matklad a=h-michael
implement #170
Co-authored-by: Hirokazu Hata <h.hata.ai.t@gmail.com>
2018-12-24 13:51:27 +00:00
bors[bot]
b052059f86
Merge #302
...
302: WIP: Support tracing lsp requests. r=DJMcNab a=DJMcNab
EDIT: We need to work out a better way to handle settings before this can be merged. Help wanted
TODO: Debug why decorations are sent even when highlightingOn is disabled
This makes the log volume so high its impossible to work with anyway.
(Continuation of #84 [#99 only disabled using it, not making sure we don't send it]).
These logs can be used in https://microsoft.github.io/language-server-protocol/inspector/
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-24 13:47:27 +00:00
Hirokazu Hata
c14ca038da
Add make_pub_crate code action to ra_editor
2018-12-24 11:03:59 +09:00
Florian Diebold
a1d0b5bc3c
Prepare Ty::new for resolution
2018-12-23 17:49:30 +01:00
gfreezy
17b35a7f7d
remove unnecessary braces in use statments
2018-12-24 00:40:36 +08:00
gfreezy
346638c809
add serverity to vscode diagnostics
2018-12-24 00:39:33 +08:00
Florian Diebold
c85748f5fb
Type the return values of call expressions
2018-12-23 17:29:03 +01:00
Florian Diebold
ef67581104
Resolve paths to defs (functions currently) during type inference
2018-12-23 17:13:11 +01:00
gfreezy
000aacafda
resolved #324 : remove unnecessary braces in use statement.
2018-12-23 23:50:11 +08:00
Florian Diebold
93ffbf80c6
Make let statements kind of work
2018-12-23 14:01:50 +01:00
Florian Diebold
5d60937090
Remove unwraps
2018-12-23 13:48:04 +01:00
Florian Diebold
b4139d54fc
Get rid of the terrible nesting in PathExpr inference
2018-12-23 13:48:04 +01:00
Florian Diebold
515c3bc59b
Cleanup
2018-12-23 13:48:04 +01:00
Florian Diebold
7348f7883f
Add testing infrastructure for type inference
...
- move dir_tests to test_utils for that.
2018-12-23 13:48:04 +01:00
Florian Diebold
3899898d75
Parse integer / float types
2018-12-23 13:48:04 +01:00
Florian Diebold
3ac605e687
Add beginnings of type infrastructure
2018-12-23 13:48:04 +01:00
DJMcNab
a0e8538129
Improve comment
2018-12-23 11:10:12 +00:00
bors[bot]
d77520fde3
Merge #310
...
310: When constructing a crate graph, detect and forbid cycles. r=matklad a=gfreezy
fixed #300
Co-authored-by: gfreezy <gfreezy@gmail.com>
2018-12-22 14:48:18 +00:00
gfreezy
c0add813e9
mark as visited on entry instead of left
2018-12-22 22:40:41 +08:00
Aleksey Kladov
5c7e8f47a8
less chatty logging
2018-12-22 15:09:08 +03:00
Aleksey Kladov
90f20f8c53
less verbose debug
2018-12-22 12:38:24 +03:00
Aleksey Kladov
94241cec04
less verbose debug for library data
2018-12-22 11:57:42 +03:00
Aleksey Kladov
2639997973
log times
2018-12-22 11:53:20 +03:00
Aleksey Kladov
49e746b010
completion uses hir scopes
2018-12-22 11:01:03 +03:00
gfreezy
0267df3815
not visit the same crateId only once
2018-12-22 15:30:58 +08:00
bors[bot]
4e4ca27eab
Merge #319
...
319: Completion icons r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-21 23:28:47 +00:00
Aleksey Kladov
ea763c73b8
fix snippet icon
2018-12-22 02:28:09 +03:00
Aleksey Kladov
498e3a6846
binding icon
2018-12-22 02:24:59 +03:00
Aleksey Kladov
8e056ef042
debug pring
2018-12-22 02:23:25 +03:00
Aleksey Kladov
97cb463c9b
moar icons
2018-12-22 02:20:14 +03:00
bors[bot]
e4d0930d9c
Merge #316
...
316: Fix handling of nested self in paths r=matklad a=DJMcNab
See https://github.com/rust-analyzer/rust-analyzer/issues/231#issuecomment-442449505 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-21 23:19:14 +00:00
Aleksey Kladov
238b52358d
more icons
2018-12-22 02:03:18 +03:00
DJMcNab
bb1ee2f13a
Move the self handling from directly inside the loop
2018-12-21 23:01:16 +00:00
Aleksey Kladov
f1f2804c71
move completion items to conv
2018-12-22 01:59:32 +03:00
DJMcNab
1dffbe5c37
Remove TODO on self_hosting_parsing
...
This improving this code is not a good use of people-time, and this
might be the most performant approach nonwithstanding
an api for this use case being added to walkdir
2018-12-21 22:44:31 +00:00
Aleksey Kladov
328d123f5b
specify completion item kind
2018-12-22 01:42:26 +03:00
Aleksey Kladov
284e894069
cleanup
2018-12-22 01:42:26 +03:00
Aleksey Kladov
25dda42f37
introduce ComletionItemKind
2018-12-22 01:42:26 +03:00
Aleksey Kladov
ebb584ce66
rename completion kind
2018-12-22 01:42:26 +03:00
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
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
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
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
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
DJMcNab
a349db7178
Run gen-tests
2018-12-20 19:10:37 +00:00
DJMcNab
1d1950336f
Use a better way of skipping SEMIs
2018-12-20 19:07:11 +00:00
DJMcNab
dc1c64f5b9
Support a blank expression before a semicolon
2018-12-20 19:07:11 +00:00
DJMcNab
0ffba1e896
Fix broken test is deleted comment
2018-12-20 17:29:26 +00:00
DJMcNab
134fe4f566
Fix the tests and fix the precommit hook
2018-12-20 16:45:54 +00:00
DJMcNab
466885aa5b
Fix missing DOTDOTEQs
2018-12-20 16:22:13 +00:00
DJMcNab
f35151afed
Don't require a command before EQ in a where clause
2018-12-20 15:50:42 +00:00
DJMcNab
84ff52390d
Rename test_fail to test_err
2018-12-20 15:09:57 +00:00
DJMcNab
63ca8bc91a
Change parser tests dir to inline/ok and inline/err
2018-12-20 15:09:22 +00:00
DJMcNab
e2a7e94518
Ensure that the parser tests pass or fail correctly
2018-12-20 13:33:00 +00:00
bors[bot]
346456f59f
Merge #301
...
301: Fix break in a condition r=matklad a=DJMcNab
The part of fixing #290 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-20 12:41:55 +00:00
DJMcNab
27e814e182
Simplify NO_BLOCK testing
2018-12-20 12:28:59 +00:00
DJMcNab
70e5fb98a0
Disable highlighting if disabled
...
This isn't working properly because we don't dynamically disable or enable it
TODO: work out why highlighting can be enabled mid session.
TODO: Improve settings handling
2018-12-20 12:16:44 +00:00
Aleksey Kladov
c96011833c
extend comment
2018-12-20 14:35:37 +03:00
DJMcNab
5205c016e9
Fix ambiguity with if break
...
Brought up by #290
2018-12-20 11:35:02 +00:00
Aleksey Kladov
bb2bafb606
docs for input queries
2018-12-20 14:12:47 +03:00
bors[bot]
d8c6b8d999
Merge #297
...
297: Use ContentModified error code r=matklad a=matklad
25679c2e4b
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-20 09:23:27 +00:00
Aleksey Kladov
b2f2621c17
Use ContentModified error code
...
25679c2e4b
2018-12-20 12:20:28 +03:00
Aleksey Kladov
a084412f06
set symbol index as const
2018-12-20 12:15:38 +03:00
Aleksey Kladov
6782fe2a5b
Treat
2018-12-20 12:15:38 +03:00
Aleksey Kladov
97812c192a
Restore library symbols
2018-12-20 12:15:38 +03:00
Aleksey Kladov
2d4582bfc6
fixme comment
2018-12-20 12:15:38 +03:00
Aleksey Kladov
2caac99ef3
resolve paths across crates
2018-12-20 12:15:38 +03:00
Aleksey Kladov
590bd5f849
workaround across-crate resolve bugs
2018-12-20 12:15:38 +03:00
Aleksey Kladov
2fe41574a1
fix tests
2018-12-20 12:15:38 +03:00
Aleksey Kladov
e6465e7e2a
index all local crates
2018-12-20 12:15:38 +03:00
Aleksey Kladov
51fec4ef84
fix the test
2018-12-20 12:15:38 +03:00
Aleksey Kladov
1b946ef8a6
File can be opened before the root is scanned
2018-12-20 12:15:38 +03:00
Aleksey Kladov
7b6bafa631
fix syc
2018-12-20 12:15:38 +03:00
Aleksey Kladov
a5ef8ad05b
swtich lsp server to vfs
2018-12-20 12:15:38 +03:00
Aleksey Kladov
6a755ed83a
remove more imports
2018-12-20 12:15:38 +03:00
Aleksey Kladov
79596abcaf
dead import
2018-12-20 12:15:38 +03:00
Aleksey Kladov
26dcc70129
fix hir mock
2018-12-20 12:15:38 +03:00
Aleksey Kladov
18aac1df45
kill file resolver
2018-12-20 12:15:38 +03:00
Aleksey Kladov
85290bc134
switch analysis to vfs
2018-12-20 12:15:38 +03:00
Aleksey Kladov
815a0e5778
doc comment
2018-12-20 12:15:38 +03:00
Aleksey Kladov
d0bab735c8
add root & path info to remove event
2018-12-20 12:15:38 +03:00
Aleksey Kladov
b6ce7a6d34
make it compile
2018-12-20 12:15:38 +03:00
Aleksey Kladov
dea1a69e1c
remove relpath from input
2018-12-20 12:15:38 +03:00
Aleksey Kladov
cb6205c09d
use relpaths for module resolve
2018-12-20 12:15:38 +03:00
Aleksey Kladov
a422d480a1
implement vfs events handling
2018-12-20 12:15:38 +03:00
Aleksey Kladov
e69b05781f
add io::Task
2018-12-20 12:15:23 +03:00
Aleksey Kladov
99561cf2f2
Add type alias
2018-12-20 12:15:23 +03:00
Aleksey Kladov
2ae05a6163
vfs crate scaffold
2018-12-20 12:15:23 +03:00
Aleksey Kladov
7509901fa0
wip
2018-12-20 12:15:23 +03:00
Jeremy A. Kolb
93cf39d968
Bump languageserver-types to 0.53.0 to support LSP 3.14.0
...
See: https://microsoft.github.io/language-server-protocol/specification#version_3_14_0
2018-12-19 17:32:44 -05:00
bors[bot]
ef1e107df1
Merge #273
...
273: Add a test to ensure that we can parse each file r=matklad a=DJMcNab
Note that this has a non-spurious failure in ra_analysis/src/mock_analysis.
Probably fixes #195 .
If my understanding is correct, fixes #214 and fixes #225 .
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-19 21:22:00 +00:00
DJMcNab
a3b842fb8b
Add tests and only traverse in the crates directory
2018-12-19 21:19:32 +00:00
DJMcNab
db67741430
Move is_block to lower in the call tree
2018-12-19 20:55:24 +00:00
DJMcNab
def0a95d35
Revert "Revert to f6f7c5"
...
This approach is correct, but it needs an addition to Restrictions too
This reverts commit ad00d0c8a5f64142e6636e8b048204c8f8982f4a.
2018-12-19 20:12:18 +00:00
DJMcNab
4dce66ad31
Fix handling of structs in match arms
2018-12-19 20:12:18 +00:00
DJMcNab
cd8e33fb7e
Revert to f6f7c5
2018-12-19 20:12:18 +00:00
DJMcNab
7a8560ba38
Fix expression parsing by bailing out upon a macro block being found
...
TODO: Fix this when the block like macro is in expression position
E.g. `test(test!{})` currently parses
2018-12-19 20:12:18 +00:00
DJMcNab
97e70bf50f
Possibly fix #225
2018-12-19 20:12:18 +00:00
DJMcNab
29bf389034
Actually fix at_ts doc comment (committed wrong file :P)
2018-12-19 20:12:18 +00:00
DJMcNab
012537bd6c
Fix at_ts doc comment
2018-12-19 20:12:18 +00:00
DJMcNab
20bbe0127c
Fix parsing of inclusive ranges ( #214 )
...
I'm not certain that this is correct, so extra eyes would be good
2018-12-19 20:12:18 +00:00
DJMcNab
0b77eec922
Add a test to ensure that we can parse each file
...
Note that this has a non-spurious failure in ra_analysis/src/mock_analysis
2018-12-19 20:12:18 +00:00
Aleksey Kladov
1c5ce7a868
File module source does not depend on syntax
2018-12-19 01:51:05 +03:00
Aleksey Kladov
d20d788571
disable gc for now
2018-12-19 01:10:03 +03:00
Aleksey Kladov
e7aa17b560
Gc syntax trees after every modification
2018-12-19 00:35:13 +03:00
Aleksey Kladov
d05790b947
Work around a bug
...
cc #288
2018-12-18 14:58:54 +03:00
Aleksey Kladov
193992fd14
move thread worker to a separate crate
2018-12-18 12:52:17 +03:00
Andrew Chin
8b1e667077
By default, log only to stderr, and not to disk.
...
This fixes a common problem when running under VS Code, the user
doesn't have permissions to create a `log` directory in the CWD.
The old behavior can be re-enabled by setting RA_INTERNAL_MODE=1
2018-12-17 17:22:30 -05:00
Roland Ruckerbauer
d0f1334226
Fixed cast expression parsing in ra_syntax.
...
The cast expression expected any type via types::type_() function,
but the language spec does only allow TypeNoBounds (types without direct extra bounds
via `+`).
**Example:**
```rust
fn test() {
6i8 as i32 + 5;
}
```
This fails, because the types::type_() function which should parse the type after the
as keyword is greedy, and takes all plus sign after path types as extra.
My proposed fix is to replace the not implemented `type_no_plus()` just calls (`type_()`)
function, which is used at several places. The replacement is `type_with_bounds_cond(p: &mut Parser, allow_bounds: bool)`, which passes the condition to relevant sub-parsers.
This function is then called by `type_()` and the new public `type_no_bounds()`.
2018-12-17 17:26:24 +01:00
Aleksey Kladov
8d42deeac3
fix installation on windows
2018-12-17 11:26:41 +03:00
Bernardo
0527e3b283
rename Edit to TextEdit and AtomEdit to AtomTextEdit
2018-12-11 19:07:17 +01:00
Bernardo
7344d28768
extract AtomEdit and Edit into new ra_text_edit crate
2018-12-10 22:09:12 +01:00
Bernardo
a062d844c2
use \b as word boundary
2018-12-09 15:50:56 +01:00
bors[bot]
3725276554
Merge #271
...
271: Implement format hook r=matklad a=DJMcNab
Tentatively: fixes #155 .
However, this does add all changes in staged files, which might not be desirable. However, I think we can't solve that without explicit support in rustfmt for it, so it should be fine.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-09 12:44:58 +00:00
DJMcNab
cbce28a348
Reimplement format-hook using a rust binary
2018-12-09 12:27:13 +00:00
Aleksey Kladov
b9c17a6001
Answer canceled requests
2018-12-09 14:43:02 +03:00
Aleksey Kladov
5004cb928b
verbose assertions in SourceFileItems
2018-12-09 14:21:54 +03:00
Aleksey Kladov
7784c7a701
resolve extern crates propertly
2018-12-09 13:49:54 +03:00
DJMcNab
279ff4927a
Update hook to not add unstaged files
2018-12-09 10:37:04 +00:00
Aleksey Kladov
e89da32bb7
move tests to separate file
2018-12-09 13:33:16 +03:00
Aleksey Kladov
6a16d3fb0b
WIP: resolve across crates
2018-12-09 13:33:16 +03:00
Aleksey Kladov
8b9ff46b37
make resolver fields private
2018-12-09 13:33:16 +03:00
Aleksey Kladov
74fe581061
return dependencies with names
2018-12-09 13:33:16 +03:00
Aleksey Kladov
961cae7e53
thread info about dep names
2018-12-09 13:33:16 +03:00
Aleksey Kladov
ca7e5905c1
more crate boilerplate
2018-12-09 13:33:16 +03:00
Aleksey Kladov
9c6c7ec2da
hir::Crate boilerplate
2018-12-09 13:33:16 +03:00
Aleksey Kladov
9b1356464a
propagate deps to CrateGraph
2018-12-09 13:33:16 +03:00
Aleksey Kladov
32c067f8c9
track deps in project model
2018-12-09 13:33:16 +03:00
DJMcNab
e823db0698
Implement and test format hook
2018-12-09 10:29:13 +00:00
Aleksey Kladov
159525b120
Check Fileid in SourceFileMap
2018-12-09 13:18:46 +03:00
Aleksey Kladov
13100da7a2
switch threadpool back from rayon to threadpool
...
rayon does not replenish the pool when the thread panics, but we must
be reselient to bugs.
2018-12-09 13:13:36 +03:00
bors[bot]
904438e993
Merge #267
...
267: Fix the extend keybinding r=DJMcNab a=DJMcNab
Make the extend selection keybinding less annoying for users not used to Injelli-J (myself included). Also fixes a minor style issue and runs `npm update`.
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-09 09:09:07 +00:00
DJMcNab
bb0c2eb8d9
Fix cargo format component name and run rustfmt
2018-12-09 09:08:10 +00:00
DJMcNab
12addc6233
Add package command and upgrade event-stream
2018-12-08 21:09:32 +00:00
Bernardo
6fb267f5da
find next whitespace or begining or end
2018-12-08 20:53:03 +01:00
bors[bot]
97b07ac393
Merge #265
...
265: Refactor symbol resolve API r=matklad a=matklad
Introduce ReferenceResolution to avoid nesting to many non-nominal
types.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-08 18:20:11 +00:00
Aleksey Kladov
7fd6a41127
Refactor symbol resolve API
...
Introduce ReferenceResolution to avoid nesting to many non-nominal
types.
2018-12-08 21:18:29 +03:00
bors[bot]
51f669606c
Merge #263
...
263: New modules r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-12-08 17:55:17 +00:00
Aleksey Kladov
7a79cde107
account for new layout when collecting tests
2018-12-08 20:54:44 +03:00
bors[bot]
5ad7547ce2
Merge #264
...
264: check for empty range when extending in comment r=matklad a=vemoo
fix for #140
Co-authored-by: Bernardo <berublan@gmail.com>
2018-12-08 17:43:15 +00:00
Bernardo
c22e901403
check for empty range when extending in comment
2018-12-08 18:26:19 +01:00
Aleksey Kladov
4cbc902fcc
grand module rename
2018-12-08 19:30:35 +03:00
Aleksey Kladov
93c0b7d794
resolve 2018 style modules
2018-12-08 19:28:35 +03:00
Aleksey Kladov
e096867ada
reformat
2018-12-08 19:28:24 +03:00
DJMcNab
f88e0700e6
Add a better text for hover and stop duplicating work done in approximatelly_resolve_symbol
2018-12-08 19:28:10 +03:00
DJMcNab
6d548d944f
Fix typo in comment
2018-12-08 19:28:10 +03:00
DJMcNab
89cf7d8743
Clarify and correct comment about multi_byte_tokens
2018-12-08 19:28:10 +03:00
DJMcNab
3d3026dc60
Fix the range of a hover request to be more in line with prior art
2018-12-08 19:28:10 +03:00
Florian Diebold
29793e7de9
Add test for code actions
2018-12-06 21:32:15 +01:00
Florian Diebold
1dfd06fc8a
Use json comparison code from cargo for heavy tests
2018-12-06 21:32:15 +01:00
Aleksey Kladov
28ddecf6c9
modernize even more
2018-12-06 21:16:37 +03:00
Aleksey Kladov
f6e8b376d1
modernize more
2018-12-06 21:03:39 +03:00
Aleksey Kladov
e477b87455
drop extern crates
2018-12-06 20:50:16 +03:00
Aleksey Kladov
1761a7d213
modernize some files
2018-12-06 20:49:36 +03:00
Aleksey Kladov
49324ee566
modernize some code
2018-12-06 20:42:03 +03:00
bors[bot]
25cf2349ab
Merge #256
...
256: Improve/add use_item documentation r=matklad a=DJMcNab
Adds some documentation to use_item explaining all code paths (use imports are hard, especially with the ongoing discussion of anchored v. uniform paths - see https://github.com/rust-lang/rust/issues/55618 for what appears to be the latest developments)
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-06 17:30:36 +00:00
Aleksey Kladov
ce6c26a60e
⬆️ 1.31.0 🎉
2018-12-06 20:22:06 +03:00
DJMcNab
455ef940fe
Update use path test
2018-12-05 22:08:00 +00:00
bors[bot]
e9060db158
Merge #253
...
253: Fix diagnostic fixes showing up everywhere r=matklad a=flodiebold
The LSP code action request always returned the fixes for all diagnostics anywhere in the file, because of a shadowed variable.
There's no test yet; I wasn't sure where to add it. I tried adding one in `heavy_tests`, but that's a bit uncomfortable because the code action response contains the (random) file paths. I could make it work, but wanted to ask beforehand what you think.
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2018-12-05 22:04:34 +00:00
DJMcNab
5da245ec33
Fix a copy and pasting typo
2018-12-05 21:46:43 +00:00
DJMcNab
0a82d768c4
Improve/add the use_item documentation
2018-12-05 21:43:40 +00:00
Aleksey Kladov
0b1c0ee225
First step towards crate deps
2018-12-05 16:01:18 +03:00
Aleksey Kladov
7ef1697df8
make stuff private
2018-12-05 15:31:40 +03:00
Aleksey Kladov
db456749a8
make stuff private
2018-12-05 13:20:11 +03:00
Aleksey Kladov
4344264024
move fuzzy source binding to a separete mode
2018-12-05 13:16:20 +03:00
Aleksey Kladov
7960c8b276
restore index-based gotodef
2018-12-05 12:17:38 +03:00
Aleksey Kladov
54d053c881
minor
2018-12-04 23:52:14 +03:00
Aleksey Kladov
d8b0379e10
Add functions to DefId
2018-12-04 23:44:00 +03:00
Aleksey Kladov
947e3350e0
module-scoped defloc
2018-12-04 23:01:53 +03:00
Aleksey Kladov
45fce90349
ModuleSource is ItemSource
2018-12-04 22:46:23 +03:00
Aleksey Kladov
a9e4142f43
include file itself in SourceFileItems
2018-12-04 21:21:39 +03:00
Florian Diebold
d0811c4066
Fix diagnostic fixes showing up everywhere
...
The LSP code action request always returned the fixes for all diagnostics
anywhere in the file, because of a shadowed variable.
2018-12-02 20:58:16 +01:00
bors[bot]
244f9a142f
Merge #250
...
250: Improve the suggestion for test functions r=DJMcNab a=DJMcNab
I haven't fully updated the previous commented out test - I don't know why it was commented out so some clarification would be welcome.
Co-authored-by: Daniel McNab <36049421+djmcnab@users.noreply.github.com>
Co-authored-by: DJMcNab <36049421+djmcnab@users.noreply.github.com>
2018-12-02 14:58:32 +00:00
DJMcNab
224e0cee5a
Fix formatting
2018-12-02 14:57:54 +00:00
bors[bot]
0bdf8deb77
Merge #252
...
252: Improve 'introduce variable' r=matklad a=flodiebold
- make it possible to extract a prefix of an expression statement (e.g.
`<|>foo.bar()<|>.baz()`)
- don't turn the last expression in a block into a let statement
- also fix a few typos
Co-authored-by: Florian Diebold <flodiebold@gmail.com>
2018-12-02 13:08:16 +00:00
Florian Diebold
2706456832
Improve 'introduce variable'
...
- make it possible to extract a prefix of an expression statement (e.g.
<|>foo.bar()<|>.baz())
- don't turn the last expression in a block into a let statement
2018-12-02 14:00:46 +01:00
Aleksey Kladov
bcc2342be6
Put derive back
...
It is used in this file
2018-12-02 12:27:30 +03:00
Aleksey Kladov
edd3768a44
Add derive
after doc comments
2018-12-02 12:19:22 +03:00
Jeremy A. Kolb
ab7843c2d1
Put map back
2018-11-30 09:39:30 -05:00
Jeremy A. Kolb
f32dc71351
Clippy lints
2018-11-29 15:30:49 -05:00
Daniel McNab
3dea87b054
Format completion text properly
2018-11-28 22:02:53 +00:00
Daniel McNab
f988441904
Add tfn lookup and remove test prefix
2018-11-28 18:39:33 +00:00
Aleksey Kladov
70a7cb34ec
switch to released id-arena
2018-11-28 21:03:30 +03:00
Daniel McNab
b47a88be9c
Change the body and name of the test function completion
2018-11-28 17:04:03 +00:00
Aleksey Kladov
555483d397
drop comment
2018-11-28 16:27:43 +03:00
Aleksey Kladov
af7a0596f6
remove useless test hooks
2018-11-28 16:25:56 +03:00
Aleksey Kladov
d30bbfda74
make a bunch of stuff private
2018-11-28 16:24:06 +03:00
Aleksey Kladov
e89700f967
Move hir tests to hit
2018-11-28 16:19:01 +03:00
Aleksey Kladov
59e29aef63
Move hir to a separate crate
2018-11-28 04:09:44 +03:00
Aleksey Kladov
0e4b710af8
introduce hir crate
2018-11-28 03:42:26 +03:00
Aleksey Kladov
f66e5b6e6b
move ids to HIR
2018-11-28 03:31:50 +03:00
Aleksey Kladov
11168c464c
move db basics to ra_db
...
This should allow to move hir to a separate crate
2018-11-28 03:25:20 +03:00
Aleksey Kladov
b2de95879a
generalize location interner
2018-11-28 02:49:28 +03:00
Aleksey Kladov
ec45dfea1e
rename file_syntax -> source_file
2018-11-28 02:25:03 +03:00
Aleksey Kladov
65c064b2a9
introduce SymbolsDatabase
2018-11-28 02:22:25 +03:00
Aleksey Kladov
201aa7ea2a
remove syntax ptr
2018-11-28 02:15:21 +03:00
Aleksey Kladov
c2abd17f57
Use ItemPtr for id
2018-11-28 02:13:52 +03:00
Aleksey Kladov
3922503205
ItemId based module source
2018-11-28 02:09:09 +03:00
Aleksey Kladov
9027a21f9a
Introduce SourceItemId
2018-11-28 01:53:54 +03:00
Aleksey Kladov
00df339c41
rename
2018-11-28 01:48:43 +03:00
Aleksey Kladov
5e7f4202cf
Move FileItems up
2018-11-28 01:45:36 +03:00
Aleksey Kladov
b9100d769a
Remove unused dead code
2018-11-28 01:41:10 +03:00
Aleksey Kladov
4c9933c016
check_canceled is a method
2018-11-28 01:38:39 +03:00
Aleksey Kladov
806ea03b64
drop descriptor suffix, use hir:: instead
2018-11-28 01:22:17 +03:00
Aleksey Kladov
36b1d20c16
rename ModuleDescriptor -> Module
2018-11-28 01:19:55 +03:00
Aleksey Kladov
16f67ee384
move resolve_local to Scopes
2018-11-28 01:11:29 +03:00
Aleksey Kladov
7207eef716
rename FnDescriptior -> FnSignatureInfo
2018-11-27 23:48:24 +03:00
Aleksey Kladov
67de38ec7d
move resolve_local_scope
2018-11-27 23:40:23 +03:00
Aleksey Kladov
93fae08261
make module module private
2018-11-27 23:35:53 +03:00
Aleksey Kladov
b7049ea543
move query definitions
2018-11-27 23:33:36 +03:00
Aleksey Kladov
90bc832b22
remove underscores
2018-11-27 23:05:33 +03:00
Aleksey Kladov
f14902f67b
move hir db
2018-11-27 23:03:08 +03:00
Aleksey Kladov
109a7f3717
itroduce FunctionDescriptor
2018-11-27 22:58:09 +03:00
Aleksey Kladov
f4d0cb64fc
rename descriptorsdb -> hirdb
2018-11-27 21:58:44 +03:00
Aleksey Kladov
d659b7a2f0
start descriptors -> hir rename
2018-11-27 21:45:42 +03:00
Aleksey Kladov
192e2bbb0e
resolve_path works with DefIds
2018-11-27 19:56:03 +03:00
Aleksey Kladov
aa7fd563a4
use ctry
2018-11-27 18:45:16 +03:00
Aleksey Kladov
f4860870da
scope-based resolve path
2018-11-27 18:25:35 +03:00
Aleksey Kladov
68f66e0f44
add db to resolve_path
2018-11-27 18:25:35 +03:00
Aleksey Kladov
5b0e347f89
Make resolve_path cancelable
2018-11-27 18:25:35 +03:00
Aleksey Kladov
6bb06addf8
don't use volatile queries
...
"volatile" means "changes every time". That is, all transitive
rev-deps of volatile queries will be executed every time. We actually
need "dependencies".
2018-11-27 17:39:58 +03:00
Aleksey Kladov
10f4d4b74c
Make nameresolution resilient to reparsing
...
We now store item id's instead of local syntax ptrs, and item ids
don't change if you type inside a single function.
2018-11-27 15:02:06 +03:00
Aleksey Kladov
4d87799a4a
implement file_items
2018-11-27 15:01:52 +03:00
Aleksey Kladov
16cdd126b6
add file items query
2018-11-27 15:01:52 +03:00
bors[bot]
8e37208040
Merge #244
...
244: Switch to id-arena r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-11-27 11:23:29 +00:00
Aleksey Kladov
ed023929d5
Switch to id-arena
2018-11-27 14:23:06 +03:00
Aleksey Kladov
6b1f30ade9
hack around nested libraries
2018-11-27 00:12:43 +03:00
Aleksey Kladov
b6fcd46278
Codify Arena pattern
2018-11-25 19:02:14 +03:00
Aleksey Kladov
ebc4e75253
switch back to the latest beta
2018-11-24 21:52:49 +03:00
Aleksey Kladov
955d2eea45
add test loggin API to db
2018-11-21 20:44:05 +03:00
Aleksey Kladov
e8c50f0915
Use :
as a trigger character for completion
...
Note that VSCode asks for completion after *first* `:` as well:
use crate:
we use hacks to protect against that, and to give completions only
after the second `:`.
2018-11-21 19:06:48 +03:00
Aleksey Kladov
edeec6a414
Complete paths after ::
2018-11-21 18:34:20 +03:00
Aleksey Kladov
7ffc7d3308
Move path completion to descriptors
2018-11-21 18:20:44 +03:00
Aleksey Kladov
11f19b7849
name res uses paths
2018-11-21 17:51:02 +03:00
Aleksey Kladov
5a87a24f82
move Path
2018-11-21 17:18:26 +03:00
Aleksey Kladov
18000ba864
docs
2018-11-21 17:07:44 +03:00
Aleksey Kladov
d47075af52
move path to descriptors
2018-11-21 16:16:54 +03:00
Aleksey Kladov
8954d4dc67
Introduce Import struct
2018-11-21 16:15:15 +03:00
Aleksey Kladov
82c088137a
Remove import_resolutions
...
It's cheaper to re-query this info anyway
2018-11-21 16:02:34 +03:00
Aleksey Kladov
5a61b218f8
Pin to older beta
...
https://github.com/rust-lang/rust/issues/56128
2018-11-21 14:47:19 +03:00
Aleksey Kladov
049f8df93c
switch completion to new scope
2018-11-21 12:57:05 +03:00
Aleksey Kladov
b70b6bce19
Move to top
2018-11-21 11:35:25 +03:00
Aleksey Kladov
ff75ad13a4
Measure time
2018-11-21 11:18:43 +03:00
Aleksey Kladov
02c4f82348
simple test for item map
2018-11-21 11:16:46 +03:00
Aleksey Kladov
36aad85138
add item map query
2018-11-21 00:39:50 +03:00
Aleksey Kladov
9bb11aee44
populate resolve from unresolved imports
2018-11-21 00:31:12 +03:00
Aleksey Kladov
aab71bff8e
move to method
2018-11-20 23:36:53 +03:00
Aleksey Kladov
cc8163439f
populate modules
2018-11-20 21:50:22 +03:00
Aleksey Kladov
1cf92c3e28
remember spans with paths
2018-11-20 21:17:14 +03:00
Aleksey Kladov
c54b51fded
add DefId
2018-11-20 21:12:15 +03:00
Aleksey Kladov
8086107b6a
implement path conversion
2018-11-20 19:40:37 +03:00
Aleksey Kladov
bcdcfa9df2
Some import resolution boilerplate
2018-11-20 19:24:58 +03:00
Aleksey Kladov
5f8068cea8
make mod private
2018-11-20 18:34:10 +03:00
Aleksey Kladov
a2fdb41ace
fix typo
2018-11-20 17:33:27 +03:00
Aleksey Kladov
8fc51501e0
Remove ModId
2018-11-20 17:23:17 +03:00
Aleksey Kladov
1913bedc2e
Make more stuff private
2018-11-20 17:21:00 +03:00
Aleksey Kladov
a300fb68e2
Make most of modules impl private
2018-11-20 17:16:33 +03:00
Aleksey Kladov
0dd26a2f5b
Use OO module API in completion
2018-11-20 17:08:40 +03:00
Aleksey Kladov
21508cfb2f
Use OO API instead of resolve_module
2018-11-20 16:55:35 +03:00
Aleksey Kladov
0ab3c65d98
Use OO API in crate_for
2018-11-20 16:40:15 +03:00
Aleksey Kladov
d475e3b29f
Make LikdId private
2018-11-20 16:24:47 +03:00
Aleksey Kladov
3b8d0c215a
Use more OO API for parent module
2018-11-20 16:21:02 +03:00
Aleksey Kladov
099da13f53
Make some queries private
...
Convention: we prefix private queries with `_` until salsa support
real visibility.
2018-11-20 14:58:01 +03:00
Aleksey Kladov
4e683d7af1
Add ModId
2018-11-20 14:52:10 +03:00
Aleksey Kladov
4e48917c00
use loc2id for FnIds
2018-11-18 16:21:23 +03:00
Aleksey Kladov
cb22a799d6
Add Loc2IdMap
2018-11-18 15:44:24 +03:00
Adolfo Ochagavía
acd51cb361
cargo format
2018-11-16 12:16:20 +01:00
Adolfo Ochagavía
bccbee5ba3
Rename col to col_utf16
2018-11-16 12:15:50 +01:00
Adolfo Ochagavía
136d1864bc
Support UTF-16 chars in LineIndex
2018-11-16 12:15:50 +01:00
Adolfo Ochagavía
c96bfe7e2d
Split string lexing and run rustfmt
2018-11-11 21:00:31 +01:00
Adolfo Ochagavía
30cd4d5acb
Validate byte string literals
2018-11-11 20:41:43 +01:00
Adolfo Ochagavía
c258b4fdb0
Add validator for byte
2018-11-11 20:27:00 +01:00
Adolfo Ochagavía
a4f7d7a7cd
Fix typos
2018-11-11 19:28:55 +01:00
Adolfo Ochagavía
3b4c02c19e
Validate string literals
2018-11-09 14:52:17 +01:00
Aleksey Kladov
8475c962a0
Fix the test
2018-11-08 18:54:19 +03:00
Aleksey Kladov
00e80b24e3
workspace-symbols function for Emacs
2018-11-08 18:43:02 +03:00
Aleksey Kladov
c69ff08dc9
eglot worksapce symbol
2018-11-08 17:40:24 +03:00
Aleksey Kladov
6d253b58da
Complete paths in use trees
2018-11-07 21:38:41 +03:00
Aleksey Kladov
06fbc6e3ed
Do more work in classify
2018-11-07 21:17:18 +03:00
Aleksey Kladov
397c235086
Use cached module scopes for completion
2018-11-07 21:08:11 +03:00
Aleksey Kladov
9b88ec488b
split completion mod
2018-11-07 20:34:16 +03:00
Aleksey Kladov
af17fc9697
reorganize completion
2018-11-07 19:50:17 +03:00
Aleksey Kladov
22949dab26
rename module source
2018-11-07 18:42:36 +03:00
Aleksey Kladov
2ed1514df3
rename ROOT -> SOURCE_FILE
2018-11-07 18:42:36 +03:00
Aleksey Kladov
f8b36bbc3b
Rename File -> SourceFileNode
2018-11-07 18:42:36 +03:00
Jeremy A. Kolb
2119fe2143
Cargo update
2018-11-07 18:42:09 +03:00
Jeremy A. Kolb
c29f158c20
Rustfmt to pass CI
2018-11-07 18:24:55 +03:00
Jeremy A. Kolb
a83ed374d0
Remove unused variable
2018-11-07 18:24:55 +03:00
Jeremy A. Kolb
8ccd26adf3
Show documentation for hover requests
2018-11-07 18:24:55 +03:00
Jeremy A. Kolb
6df71da81f
Add some more DocCommentsOwner
2018-11-07 18:24:55 +03:00
bors[bot]
2e2445444a
Merge #207
...
207: Finish implementing char validation r=aochagavia a=aochagavia
The only thing missing right now are good integration tests (and maybe more descriptive error messages)
Co-authored-by: Adolfo Ochagavía <github@adolfo.ochagavia.xyz>
2018-11-07 11:09:40 +00:00
Adolfo Ochagavía
433a806191
Fix backslash escape
2018-11-07 12:04:26 +01:00
Adolfo Ochagavía
3b2ba59526
Use ArrayString instead of hand rolled data structure
2018-11-07 11:58:34 +01:00
Adolfo Ochagavía
e37ba706cc
cargo format
2018-11-07 11:41:42 +01:00
Adolfo Ochagavía
94796e6447
Add lots of tests
2018-11-07 11:35:33 +01:00
Adolfo Ochagavía
fdb9f06880
Store hex digits in a stack-allocated buffer
2018-11-07 10:40:58 +01:00
Aleksey Kladov
8eaf7952ae
ra_syntax::File is just RootNode
2018-11-06 23:26:26 +03:00
Aleksey Kladov
7f88fe8790
Add a pinch of comments
2018-11-06 22:06:58 +03:00
Aleksey Kladov
a5301e94d5
Generalize Owned nodes
2018-11-06 21:52:00 +03:00
Aleksey Kladov
ec131b6c7b
grammar: fix where clause parsing
...
closes #205
2018-11-06 21:19:32 +03:00
Aleksey Kladov
dafe747dcc
upstream basic tree algorithms to rowan
2018-11-06 20:56:32 +03:00
Adolfo Ochagavía
c56db92d1f
Finish implementing char validation
2018-11-06 17:07:27 +01:00
Jeremy A. Kolb
5a9d471f98
Use closing paren as a trigger character
...
This seems counter-intuitive based on the concept of "trigger character"
but it provides a better function signature experience.
2018-11-05 17:13:56 -05:00
bors[bot]
f605f6e70a
Merge #188
...
188: Introduce `SyntaxErrorKind` and `TextRange` to `SyntaxError` r=matklad a=aochagavia
Co-authored-by: Adolfo Ochagavía <aochagavia92@gmail.com>
Co-authored-by: Adolfo Ochagavía <github@adolfo.ochagavia.xyz>
2018-11-05 21:32:25 +00:00
Adolfo Ochagavía
59405bfe4a
cargo format
2018-11-05 22:29:33 +01:00
Adolfo Ochagavía
fda8ddc5fe
Introduce Location and make SyntaxError fields private
2018-11-05 18:38:34 +01:00
Aleksey Kladov
43665eb166
bring back testutils
2018-11-05 15:56:07 +03:00
Aleksey Kladov
8e8f52e80a
add description
2018-11-05 15:52:22 +03:00
Aleksey Kladov
80e50cae00
Switch ra_syntax to 2015 edition
2018-11-05 15:47:59 +03:00
Aleksey Kladov
420725f256
Introduce var works with tail exprs
2018-11-05 15:44:34 +03:00
Aleksey Kladov
0192c116f7
Use FilePosition everywhere
2018-11-05 14:57:41 +03:00
Aleksey Kladov
1e1c188cbf
rename Position to FilePostion
2018-11-05 14:24:38 +03:00
Aleksey Kladov
8b132354bb
don't send backtraces for canceled requests
2018-11-05 14:22:39 +03:00
Aleksey Kladov
6bbcfca7ae
Fully add inline modules to module tree
2018-11-05 14:10:20 +03:00
Aleksey Kladov
44d8919384
Submodule is enum
2018-11-05 13:23:37 +03:00
Aleksey Kladov
17a88928f4
collect all submodules
2018-11-05 13:08:52 +03:00
Aleksey Kladov
e0b21b9899
submodules works with module sources
2018-11-05 12:36:38 +03:00
Aleksey Kladov
88a15d10d5
use module_for_source
2018-11-05 12:36:38 +03:00
Aleksey Kladov
cd878658d3
Introduce modules_from_source fn
2018-11-05 12:36:38 +03:00
Aleksey Kladov
6502bd2c96
reduce code duplication
2018-11-05 11:39:51 +03:00
Aleksey Kladov
9010cb9839
grammar: for predicates in where
...
closes #191
2018-11-05 11:24:08 +03:00
Adolfo Ochagavía
3b42ddae60
Introduce SyntaxErrorKind and TextRange in SyntaxError
2018-11-04 21:16:38 +01:00
Adolfo Ochagavía
9b5bbab104
Add character literal parsing and validation
2018-11-04 15:17:24 +01:00
Aleksey Kladov
f29b0172fb
Use Default everywhere
2018-11-04 14:09:21 +03:00
Aleksey Kladov
cca5f862de
Don't order import alphabetical
...
alphabetical ordering is no more consistent, and much less useful then
the ordering which arises naturally when you add import.
2018-11-01 16:18:53 +03:00
Aleksey Kladov
c74e86536e
Dead code
2018-11-01 16:00:13 +03:00
Aleksey Kladov
a17b41033a
update salsa
2018-11-01 15:30:07 +03:00
Aleksey Kladov
962a491829
Some docs
2018-11-01 14:31:35 +03:00
Aleksey Kladov
f2b654fd44
Add inline source
2018-11-01 13:51:44 +03:00
Aleksey Kladov
223fd2979c
Introduce ModuleSource
2018-11-01 13:41:58 +03:00
Aleksey Kladov
d685a9b564
Use From to get an owned AST
2018-11-01 13:41:20 +03:00
bors[bot]
3ec9f958b3
Merge #179
...
179: Remove DOC_COMMENT r=matklad a=kjeremy
Closes #166
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-11-01 10:16:24 +00:00
Aleksey Kladov
2050812cad
remove SyntaxPtrDatabase
2018-11-01 13:15:11 +03:00
Jeremy A. Kolb
61580f3cb8
Remove DOC_COMMENT
...
Closes #166
2018-10-31 17:38:18 -04:00
Aleksey Kladov
2b210d98b8
Fix test
2018-11-01 00:00:43 +03:00
Aleksey Kladov
fabb804f30
Speedup fmt
2018-10-31 23:58:03 +03:00
Aleksey Kladov
8f1a83b4cb
RemoveDeadCode
2018-10-31 23:50:18 +03:00
Aleksey Kladov
6be50f7d5d
Reformat all
2018-10-31 23:41:43 +03:00
Muhammad Mominul Huque
857c1650ef
Various changes
...
Pin to a specific toolchain version
Format checking functionality
Add a test to check the code formatting.
Remove macro_use attribute
2018-10-31 23:39:21 +03:00
Muhammad Mominul Huque
d14610dab4
initial implementation
2018-10-31 23:39:21 +03:00
Jeremy A. Kolb
9b9fc135d6
Simplify find_all_refs by always resolving a ast::BindPat
2018-10-31 23:38:22 +03:00
Jeremy A. Kolb
406f366ccc
Add DeclarationDescriptor and ReferenceDescriptor
...
Fixes #142
Fixes #146
2018-10-31 23:30:57 +03:00
bors[bot]
55ebe6380a
Merge #167
...
167: Attempt to extract useful comments from function signatures r=matklad a=kjeremy
I'm trying to extract useful function comments for signature info. This will also be useful for hover. This is a WIP (and actually works pretty well!) but I don't think it's the right approach long term so some guidance would be appreciated so that we could also get comments for say types and variable instances etc.
Currently `test_fn_signature_with_simple_doc` fails due to a bug in `extend` but we probably shouldn't use this approach anyway. Maybe comments should be attached to nodes somehow? I'm also thinking that maybe the markdown bits should live in the language server.
Thoughts?
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-31 19:41:24 +00:00
Aleksey Kladov
dfba29e4fb
Add MockAnalysis to make testing easier
2018-10-31 22:35:01 +03:00
Jeremy A. Kolb
74320945b6
Make extend private again
2018-10-31 15:27:35 -04:00
Jeremy A. Kolb
05eb489ec5
Useful comments from function signatures
2018-10-31 15:23:20 -04:00
Jeremy A. Kolb
d2bcd1a386
ast::DocCommentsOwner
which represents a documentation comment owner
2018-10-31 15:08:37 -04:00
Jeremy A. Kolb
3c2aefc274
Prevent panic by initializing LibrariesQuery
2018-10-31 14:53:09 -04:00
Aleksey Kladov
64ce895ef0
extract fixture parsing
2018-10-31 21:37:40 +03:00
bors[bot]
b58ca6b1a6
Merge #177
...
177: Librariese -> Libraries r=matklad a=kjeremy
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-31 18:16:58 +00:00
Jeremy A. Kolb
542fbcbaed
Fix typo
2018-10-31 14:05:14 -04:00
bors[bot]
1dc5608d0b
Merge #176
...
176: Move completio to ra_analysis r=matklad a=matklad
While we should handle completion for isolated file, it's better
achieved by using empty Analysis, rather than working only with &File:
we need memoization for type inference even inside a single file.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-10-31 18:05:12 +00:00
Jeremy A. Kolb
e60ef6260f
Fix typos
2018-10-31 21:04:38 +03:00
Aleksey Kladov
c09e14a4ff
remove old completion
2018-10-31 21:03:00 +03:00
Aleksey Kladov
f3fb59d707
Move completion to ra_analysis
...
While we should handle completion for isolated file, it's better
achieved by using empty Analysis, rather than working only with &File:
we need memoization for type inference even inside a single file.
2018-10-31 21:01:51 +03:00
Aleksey Kladov
c02be1502c
move resolve local name
2018-10-31 15:13:49 +03:00
Aleksey Kladov
b67295134b
Move FnDescriptors to analyzer
2018-10-31 10:56:31 +03:00
Aleksey Kladov
3068af79ff
Introduce owned ast nodes
...
ast::FooNode is an owned 'static counterpart to ast::Foo<'a>
2018-10-31 10:29:32 +03:00
bors[bot]
032d15c392
Merge #171
...
171: Query-based module scopes r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-10-30 23:10:48 +00:00
Aleksey Kladov
fbbee53722
Add ModuleScope as a query
...
This is a first step towards queryifing completion and resolve.
Some code currently duplicates ra_editor: the plan is to move all
completion from ra_editor, but it'll take more than one commit.
2018-10-31 02:08:54 +03:00
Aleksey Kladov
23cad90fe9
⬆️ salsa
2018-10-31 01:22:47 +03:00
bors[bot]
d10214581e
Merge #168
...
168: Fix param number r=matklad a=kjeremy
Fixes the parameter number if we are not in a method
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-30 21:50:51 +00:00
Aleksey Kladov
1643d94a65
switch to TextRange::subrange
2018-10-30 21:26:55 +03:00
Aleksey Kladov
950e8b8182
introduce syntax-ptr
2018-10-30 21:23:23 +03:00
Jeremy A. Kolb
93dc703011
Fix param number
2018-10-30 14:09:53 -04:00
Aleksey Kladov
bc4de7128f
gc syntax trees
2018-10-29 13:58:11 +03:00
Aleksey Kladov
35568cf057
Index files in parallel
2018-10-29 13:32:45 +03:00
Aleksey Kladov
363adf07b7
restore symbols filtering
2018-10-25 17:59:03 +03:00
Aleksey Kladov
d190019571
Move input to top-level
2018-10-25 17:52:50 +03:00
Aleksey Kladov
5ef3fda5e1
Remove unneded Hash
2018-10-25 17:43:17 +03:00
Aleksey Kladov
e7217e1a01
dead code
2018-10-25 17:42:29 +03:00
Aleksey Kladov
3c024d6c62
dead code
2018-10-25 17:41:17 +03:00
Aleksey Kladov
e0eb33605a
Encapsulate CrateGraph a bit
2018-10-25 17:40:24 +03:00
Aleksey Kladov
75d9cbd7c2
re-enable cancelation
2018-10-25 17:22:31 +03:00
Aleksey Kladov
772acb53f2
use correct file when resolving callables
2018-10-25 16:25:40 +03:00
Aleksey Kladov
171acad15b
disable cancelation
2018-10-25 16:25:40 +03:00
Aleksey Kladov
56df0fc83c
Improve logging
2018-10-25 16:25:40 +03:00
Aleksey Kladov
ee4d904cfb
Store all the data in the Salsa Database
2018-10-25 16:25:40 +03:00
Aleksey Kladov
bca5a41dff
Fix the test
2018-10-25 13:47:31 +03:00
Aleksey Kladov
48fa1f8ba0
More informative lable for check runnable
2018-10-25 11:01:37 +03:00
Aleksey Kladov
6660101554
specify package when running cargo check
2018-10-25 10:56:12 +03:00
Aleksey Kladov
0e359af291
Always add cargo check as a runnable
2018-10-25 10:29:39 +03:00
Aleksey Kladov
69d07df201
Complete crate:: paths
2018-10-24 18:37:25 +03:00
Aleksey Kladov
9a7db8fa00
simplify roots
2018-10-24 17:25:10 +03:00
Aleksey Kladov
8ada1a2689
Simplify
2018-10-24 16:36:28 +03:00
Aleksey Kladov
44c8ddf885
make indexing parallel again
2018-10-24 16:13:17 +03:00
Aleksey Kladov
b636d23bec
revive the test
2018-10-24 15:00:03 +03:00
bors[bot]
ffbb604363
Merge #157
...
157: Introduce ModuleId r=matklad a=matklad
Previously, module was synonym with a file, and so a module could have
had several parents. This commit introduces a separate module concept,
such that each module has only one parent, but a single file can
correspond to different modules.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-10-23 17:57:10 +00:00
Aleksey Kladov
dc477db757
Introduce ModuleId
...
Previously, module was synonym with a file, and so a module could have
had several parents. This commit introduces a separate module concept,
such that each module has only one parent, but a single file can
correspond to different modules.
2018-10-23 20:44:23 +03:00
bors[bot]
e49c628c0d
Merge #156
...
156: Cargo Update run r=kjeremy a=kjeremy
Bump relative-path to 0.4.0
Failure 0.1.3 to fix leak with downcast
Updated everything else too
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-23 13:59:56 +00:00
Jeremy A. Kolb
0ee37099b5
Cargo Update run
...
Bump relative-path to 0.4.0
Failure 0.1.3 to fix leak with downcast
Updated everything else too
2018-10-23 09:46:00 -04:00
Aleksey Kladov
1d574ed654
complete pub(crate)
2018-10-23 16:42:07 +03:00
bors[bot]
ed736b1ac1
Merge #153
...
153: Restore folding import groups r=matklad a=aochagavia
Closes #133
Co-authored-by: Adolfo Ochagavía <github@adolfo.ochagavia.xyz>
2018-10-23 13:28:05 +00:00
Adolfo Ochagavía
7ee10b073e
Restore folding import groups
2018-10-23 14:58:02 +02:00
bors[bot]
0043d7e9c7
Merge #151
...
151: Add LspError to explicity return errors from LSP handlers r=matklad a=kjeremy
Fixes #145
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-23 12:28:57 +00:00
bors[bot]
fd7f6beedc
Merge #152
...
152: Fix typo r=matklad a=kjeremy
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-22 22:00:42 +00:00
bors[bot]
27694abd94
Merge #138
...
138: Fix some clippy lints r=matklad a=alanhdu
I went ahead and fixed all the clippy lints (there were a couple I thought would be better unfixed and added `cfg` statements to allow them) and also re-enabled clippy and rustfmt in CI.
They were disabled with `no time to explain, disable clippy checks`, so hopefully this won't go against whatever the reason at the time was 😆 .
One question about the CI though: right now, it's an allowed failure that runs against the latest nightly each time. Would it be better to pin it to a specific nightly (or use the `beta` versions) to lower the churn?
Co-authored-by: Alan Du <alanhdu@gmail.com>
2018-10-22 21:14:38 +00:00
Jeremy A. Kolb
652afa17ad
Fix typo
2018-10-22 13:55:17 -04:00
Jeremy A. Kolb
6453b29cb5
Add LspError to explicity return errors from LSP handlers
...
Fixes #145
2018-10-22 13:49:27 -04:00
Alan Du
dc9ce8ff74
Rename new to new_item (to match new_impl)
2018-10-22 10:50:55 -04:00
Aleksey Kladov
dbe2880219
cleanup
2018-10-20 23:27:06 +03:00
Aleksey Kladov
0102a01f76
Remove job handle
2018-10-20 22:59:54 +03:00
Aleksey Kladov
8bb4380448
Fix tests
2018-10-20 22:43:36 +03:00
Aleksey Kladov
6e88aaef5d
use pythonic import order
...
use std
// blank line
use extern crates
// blank line
use crate::{}
2018-10-20 22:38:52 +03:00
Aleksey Kladov
8eea10e3ab
actually check for cancelation
2018-10-20 22:35:55 +03:00
Aleksey Kladov
71cbdddf1c
make file-symbols query cancelable
2018-10-20 22:29:26 +03:00
Aleksey Kladov
e74bf6e56e
mark module queries as cacelable
2018-10-20 22:15:03 +03:00
Aleksey Kladov
9fb41716de
make more things cancelable
2018-10-20 22:09:12 +03:00
Aleksey Kladov
998f2ae762
remove job tokens
2018-10-20 22:02:41 +03:00
Aleksey Kladov
c4b0d3cd56
make parent module cancelable
2018-10-20 21:52:49 +03:00
Aleksey Kladov
61518580ed
introduce cancelable
2018-10-20 21:46:17 +03:00
Alan Du
0857c22f26
Revert "clippy: Fix new_ret_no_self"
...
This reverts commit 2ae9dfa812
.
2018-10-20 12:29:25 -04:00
Aleksey Kladov
73dd870da2
update salsa
2018-10-20 18:43:02 +03:00
bors[bot]
2ded93a78a
Merge #143
...
143: Implement Find All References and Rename for local variables r=matklad a=kjeremy
Expose `find_all_refs` in `Analysis`. This currently only works for local variables.
Use this in the LSP to implement find all references and rename.
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-20 12:51:30 +00:00
Jeremy A. Kolb
9f9e41885c
LSP: Add support for prepareRename
2018-10-19 15:25:10 -04:00
Jeremy A. Kolb
2844c8fdfa
Handle renaming of local variables
2018-10-18 17:56:22 -04:00
Jeremy A. Kolb
3746689e9d
Implement Find All References for local variables
2018-10-18 13:40:12 -04:00
Alan Du
6dd3fa6a94
clippy: cast_lossless
2018-10-17 19:42:23 -04:00
Alan Du
a5da770ec6
Fix function calls
2018-10-17 19:42:23 -04:00
Alan Du
fc8024de51
clippy: type_complexity
2018-10-17 19:42:23 -04:00
Alan Du
bc774fe6cf
clippy: needless_lifetimes
2018-10-17 19:42:23 -04:00
Alan Du
2ae9dfa812
clippy: Fix new_ret_no_self
2018-10-17 19:42:23 -04:00
Alan Du
2268a2f8c6
Silence clippy::derive_hash_xor_eq
...
Manually implement PartialEq
2018-10-17 19:42:23 -04:00
Alan Du
4e8ea94e2b
Remove Copy trait on LeafAtOffset
...
Because it's a stateful iterator, it's easier to explicitly clone it
when necesary.
Fixes clippy:clone_on_copy
2018-10-17 19:42:23 -04:00
Alan Du
d493a4476c
clippy: Use if lets and remove redundant returns
2018-10-17 19:42:23 -04:00
Alan Du
5db663d61f
Clippy lint: single-character string constant
2018-10-17 19:42:23 -04:00
Aleksey Kladov
00cdde2c52
Update rowan
2018-10-17 19:52:25 +03:00
Aleksey Kladov
2f4a248f80
rename gen-kinds to gen-syntax
2018-10-16 21:17:19 +03:00
Aleksey Kladov
b43bcd43c6
fix tests
2018-10-16 20:53:19 +03:00
Aleksey Kladov
0b6d4983de
Switch to published teraron
2018-10-16 20:36:45 +03:00
Aleksey Kladov
514aa3cf85
extract teraron
2018-10-16 20:31:30 +03:00
Jeremy A. Kolb
61f3a438d3
Cargo Format
...
Run `cargo fmt` and ignore generated files
2018-10-16 09:41:10 -04:00
bors[bot]
39cb6c6d3f
Merge #128
...
128: Add a test to verify if the generated codes are up-to-date. r=matklad a=mominul
This test checks if the generated codes are up-to-date every time during `cargo test`.
I have confirmed that the test works by manually editing the `grammar.ron` file.
Closes #126
Thanks!
Co-authored-by: Muhammad Mominul Huque <mominul2082@gmail.com>
2018-10-16 12:24:26 +00:00
Muhammad Mominul Huque
2c4cfb297e
take &Path
instead of PathBuf
2018-10-16 15:36:53 +06:00
Aleksey Kladov
f30a7deff1
switch to salsa release
2018-10-15 23:57:46 +03:00
Aleksey Kladov
fc31ddd303
Simplify
2018-10-15 22:59:18 +03:00
Aleksey Kladov
85ff328d31
remove clones
2018-10-15 22:36:08 +03:00
Aleksey Kladov
bbcd998433
make analysis sync
2018-10-15 22:29:24 +03:00
Aleksey Kladov
76c51fae77
Tweak writable root API
2018-10-15 22:05:21 +03:00
Aleksey Kladov
8c88900fa9
remove resolver from world
2018-10-15 22:01:50 +03:00
Aleksey Kladov
ee69fddf02
Drop dead code
2018-10-15 21:56:01 +03:00
Muhammad Mominul Huque
9d9e637ef3
Refactor the constants
2018-10-16 00:54:27 +06:00
Aleksey Kladov
7503c5528f
fix tests
2018-10-15 21:54:12 +03:00
Aleksey Kladov
062019590d
Switch to the master of salsa
2018-10-15 21:25:54 +03:00
Aleksey Kladov
d783371b86
migrate modue map to salsa
2018-10-15 21:20:20 +03:00
Aleksey Kladov
d8aee31a60
start salsa migration
2018-10-15 21:19:49 +03:00
Aleksey Kladov
93d77e9b22
remove our own copy of salsa
...
salsa-rs/salsa is faster and more type safe
2018-10-15 21:12:19 +03:00
Aleksey Kladov
64b879d6a9
add salsa dep, break the world
2018-10-15 21:12:06 +03:00
Aleksey Kladov
9a98d8e99a
regenerate
2018-10-15 20:54:07 +03:00
Aleksey Kladov
376639c70f
Parse crate paths in expressions
2018-10-15 20:52:56 +03:00
Muhammad Mominul Huque
ce73df065f
Use CARGO_MANIFEST_DIR for locating the grammar.ron file
2018-10-15 23:52:11 +06:00
Aleksey Kladov
bb298158eb
migrate analysis and server to 2018
2018-10-15 20:15:53 +03:00
Aleksey Kladov
2dd6858d03
switch ra_cli to 2018
2018-10-15 20:06:02 +03:00
Aleksey Kladov
1624bf2d7f
switch editor to 2018
2018-10-15 20:05:26 +03:00
Aleksey Kladov
9434920648
switch base crates to 2018
2018-10-15 20:00:54 +03:00
Aleksey Kladov
171c176833
Run cargo fix
2018-10-15 19:55:32 +03:00
bors[bot]
a230b438e0
Merge #127
...
127: Improve folding r=matklad a=aochagavia
I was messing around with adding support for multiline comments in folding and ended up changing a bunch of other things.
First of all, I am not convinced of folding groups of successive items. For instance, I don't see why it is worthwhile to be able to fold something like the following:
```rust
use foo;
use bar;
```
Furthermore, this causes problems if you want to fold a multiline import:
```rust
use foo::{
quux
};
use bar;
```
The problem is that now there are two possible folds at the same position: we could fold the first use or we could fold the import group. IMO, the only place where folding groups makes sense is when folding comments. Therefore I have **removed folding import groups in favor of folding multiline imports**.
Regarding folding comments, I made it a bit more robust by requiring that comments can only be folded if they have the same flavor. So if you have a bunch of `//` comments followed by `//!` comments, you will get two separate fold groups instead of a single one.
Finally, I rewrote the API in such a way that it should be trivial to add new folds. You only need to:
* Create a new FoldKind
* Add it to the `fold_kind` function that converts from `SyntaxKind` to `FoldKind`
Fixes #113
Co-authored-by: Adolfo Ochagavía <github@adolfo.ochagavia.xyz>
2018-10-15 16:48:17 +00:00
Muhammad Mominul Huque
33b378797c
Show how to generate code with error message
2018-10-14 20:58:53 +06:00
Muhammad Mominul Huque
114e9a2d74
create cli.rs and make the tests passing
2018-10-14 20:32:57 +06:00
Adolfo Ochagavía
2bc9e9f327
Improve tests
2018-10-13 21:33:15 +02:00
Adolfo Ochagavía
c5069eeef5
Only fold groups of similar comments
2018-10-13 15:37:44 +02:00
Adolfo Ochagavía
4b3737510b
Cleanup fold code and split logic to fold single elements
2018-10-12 19:20:58 +02:00
Jeremy A. Kolb
c9909f42ba
A FnDescriptor shouldn't exist without a name
2018-10-12 07:54:57 -04:00
Jeremy A. Kolb
3ac5199755
Regenerate
2018-10-12 07:43:37 -04:00
Adolfo Ochagavía
ee0a6bf053
Fold multiline comments
2018-10-12 08:59:12 +02:00
Jeremy A. Kolb
f8a2b53304
Language Server: textDocument/signatureHelp
...
Implements a pretty barebones function signature help mechanism in
the language server.
Users can use `Analysis::resolve_callback()` to get basic information
about a call site.
Fixes #102
2018-10-11 16:40:46 -04:00
bors[bot]
2ba6f18586
Merge #122
...
122: Use rustc-hash crate r=matklad a=mominul
Replace std's HashMap, HashSet with FxHashMap and FxHashSet.
Closes #121
Thanks!
Co-authored-by: Muhammad Mominul Huque <mominul2082@gmail.com>
2018-10-11 18:28:44 +00:00
Muhammad Mominul Huque
dc2b30e9b6
Replace HashMap, HashSet with FxHashMap and FxHashSet
2018-10-12 00:07:44 +06:00
bors[bot]
77e9bf9b5f
Merge #116
...
116: Collapse comments upon join r=matklad a=aochagavia
Todo:
- [x] Write tests
- [x] Resolve fixmes
- [x] Implement `comment_start_length` using the parser
I left a bunch of questions as fixmes. Can someone take a look at them? Also, I would love to use the parser to calculate the length of the leading characters in a comment (`//`, `///`, `//!`, `/*`), so any hints are greatly appreciated.
Co-authored-by: Adolfo Ochagavía <aochagavia92@gmail.com>
Co-authored-by: Adolfo Ochagavía <github@adolfo.ochagavia.xyz>
2018-10-11 15:43:34 +00:00
Adolfo Ochagavía
6fe77db413
Remove smart multiline comment join
2018-10-11 17:16:12 +02:00
Adolfo Ochagavía
92f5ca64ae
Add tests
2018-10-11 17:11:59 +02:00
Adolfo Ochagavía
5508c91b3e
Remove nesting
2018-10-11 16:45:52 +02:00
Adolfo Ochagavía
f88e13f539
Use Comment wrapper
2018-10-11 16:25:35 +02:00
bors[bot]
9b155c8976
Merge #118
...
118: Remove error publishing through publishDecorations r=matklad a=aochagavia
The errors are already reported by `publishDiagnostics`
Closes #109
Co-authored-by: Adolfo Ochagavía <aochagavia92@gmail.com>
2018-10-11 09:18:33 +00:00
Reinier Maas
6abecf76e5
Update crates/ra_syntax/src/ast/generated.rs
...
effect of running cargo gen-kinds
2018-10-10 17:26:01 +02:00
Reinier Maas
c579b47b4a
Update generated.rs.tera
...
Removing `-` for #114
2018-10-10 17:18:21 +02:00
Adolfo Ochagavía
edd162bda8
Report errors only once
2018-10-10 16:59:46 +02:00
Adolfo Ochagavía
26d34cc443
Remove error publishing through publishDecorations
2018-10-10 16:49:32 +02:00
Adolfo Ochagavía
27a86cb7df
Collapse comments upon join
2018-10-10 12:37:06 +02:00
bors[bot]
31c8ebb743
Merge #106
...
106: Add on-enter handler r=matklad a=matklad
Now, typing doc comments is much more pleasant
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-10-09 16:52:48 +00:00
Aleksey Kladov
2b956fd3a8
Add on-enter handler
...
Now, typing doc comments is much more pleasant
2018-10-09 19:52:06 +03:00
Aleksey Kladov
5d1dae83a1
Switch to absolute offsets for extend comment word
2018-10-09 18:53:35 +03:00
Aleksey Kladov
239213a3db
Prepare gen_lsp_server for publishing
2018-10-09 12:55:23 +03:00
Aleksey Kladov
a05e09e9c5
Attach comments smartly
2018-10-08 17:36:38 +03:00
Aleksey Kladov
b642e6c645
replace loop with iterators
2018-10-08 15:46:14 +03:00
Aleksey Kladov
86a7ac2d31
Simplify event processing
2018-10-08 15:44:00 +03:00
Aleksey Kladov
3c12d38a32
tfn snippet
2018-10-08 14:08:31 +03:00
bors[bot]
e4fdfd1501
Merge #98
...
98: WIP: Add resolve_local_name to resolve names in a function scope r=kjeremy a=kjeremy
First step to resolving #80
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-07 17:01:57 +00:00
Jeremy A. Kolb
ff1b2da502
Remove functional noop
2018-10-06 13:41:33 -04:00
Jeremy A. Kolb
828bd73195
Resolve local names first
2018-10-06 12:02:15 -04:00
Jeremy A. Kolb
1d4c767879
WIP: This doesn't currently work but I also don't think it's the right abstraction
2018-10-05 15:21:40 -04:00
Jeremy A. Kolb
91312a9ff9
Add resolve_local_name to resolve names in a function scope
2018-10-05 10:53:17 -04:00
Daniel McNab
80eefcbc05
Add cargo gen-kinds
documentation
2018-10-04 21:43:58 +01:00
bors[bot]
81bf190f7a
Merge #94
...
94: Extend comments by single word first r=matklad a=kjeremy
Fixes #88
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-10-04 14:25:53 +00:00
Jeremy A. Kolb
a30039ba62
Pull casts out of TextUnit
2018-10-04 09:39:02 -04:00
Jeremy A. Kolb
334d266b77
Simplify extend_single_word_in_comment
2018-10-04 09:35:55 -04:00
bors[bot]
7a025ad201
Merge #93
...
93: Support leading pipe in match arms r=matklad a=DJMcNab
This adds support for match arms of the form:
```rust
<...>
| X | Y => <...>,
| X => <...>,
| 1..2 => <...>,
etc
```
# Implementation discussion
This just naïvely 'eats' a leading pipe if one is available. The equivalent line in the reference `libsyntax` is in [`parse_arm`](441519536c/src/libsyntax/parse/parser.rs (L3552)
).
As noted in the comment linked above, this feature was formally introduced as a result of rust-lang/rfcs#1925 . This feature is in active use in the [`rust-analyzer` codebase](c87fcb4ea5/crates/ra_syntax/src/syntax_kinds/generated.rs (L231)
)
I have added some tests for this feature, but maybe more would be required
EDIT: Always looking for feedback - is this PR description over-engineered?
Co-authored-by: Daniel McNab <36049421+djmcnab@users.noreply.github.com>
2018-10-04 07:02:19 +00:00
Jeremy A. Kolb
4c2be06a7e
Extend comments by single word first
...
Fixes #88
2018-10-03 17:04:00 -04:00
Daniel McNab
a55ef9b3ed
Support leading pipe in match arms
2018-10-03 21:47:03 +01:00
Aleksey Kladov
1a2a8dec14
Make siblings an inherent method
2018-10-02 18:14:33 +03:00
Aleksey Kladov
d323c81d5c
make ancestors and descendants inherent
2018-10-02 18:02:57 +03:00
Aleksey Kladov
dccaa5e45e
use aliases
2018-10-02 17:50:56 +03:00
Aleksey Kladov
a261a1836b
Move to rowan for syntax tree impl
2018-10-02 17:09:23 +03:00
Aleksey Kladov
804e29402a
fix code actions
2018-09-29 21:59:34 +03:00
Aleksey Kladov
baaf027da0
support 2018 paths
2018-09-29 14:53:23 +03:00
bors[bot]
5e1d109cbb
Merge #81
...
81: [WIP] Reject impl keyword inside impl header r=matklad a=csmoe
Closes #77
Co-authored-by: csmoe <35686186+csmoe@users.noreply.github.com>
2018-09-26 20:14:28 +00:00
csmoe
8b710e9535
generate testsuite for impl_type
2018-09-26 16:53:16 +08:00
csmoe
edf1cc3582
parse impl type
2018-09-25 22:21:16 +08:00
Jeremy A. Kolb
4d52d004d5
Unit Tests
2018-09-24 10:48:13 -04:00
Jeremy A. Kolb
ff0a706a30
Split folding ranges into editor and lsp parts
2018-09-24 09:52:33 -04:00
csmoe
cacb32d88a
reject impl keyword in impl header
2018-09-24 11:44:43 +08:00
csmoe
e446316585
add test for impl recovery
2018-09-24 11:44:43 +08:00
Jeremy A. Kolb
bd2b2f1b48
Implement folding ranges
2018-09-23 11:19:36 -04:00
Jeremy A. Kolb
e293a16d6b
Support LSP 3.13
2018-09-23 11:10:57 -04:00
bors[bot]
f5808b21a4
Merge #75
...
75: libsyntax2 -> rust-analyzer r=matklad a=kjeremy
Change a few `libsyntax2` to `rust-analyzer`
Co-authored-by: Jeremy A. Kolb <jkolb@ara.com>
2018-09-19 10:56:31 +00:00
Aleksey Kladov
4d5cfd7229
prefer lifetimes in extend selection
2018-09-19 13:55:47 +03:00
Aleksey Kladov
d6c7030aeb
Add emacs function for extend shirnk selection
2018-09-19 00:46:10 +03:00
Jeremy A. Kolb
8845b50438
libsyntax2 -> rust-analyzer
2018-09-18 17:40:33 -04:00
Aleksey Kladov
79293d2593
eprintln
2018-09-16 17:24:18 +03:00
Aleksey Kladov
b5021411a8
rename all things
2018-09-16 13:07:39 +03:00
Aleksey Kladov
ba0bfeee12
fix derecated call
2018-09-16 03:06:56 +03:00
Aleksey Kladov
5b70e5cf0c
fix installation for windows
2018-09-16 00:02:25 +01:00
Aleksey Kladov
722706fe41
get rid of commandspeck
2018-09-16 02:12:53 +03:00
bors[bot]
3993bb4de9
Merge #67
...
67: Salsa r=matklad a=matklad
The aim of this PR is to transition from rather ad-hock FileData and ModuleMap caching strategy to something resembling a general-purpose red-green engine.
Ideally, we shouldn't recompute ModuleMap at all, unless the set of mod decls or files changes.
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-09-15 21:11:25 +00:00
Aleksey Kladov
fcdf3a52b4
everysalsa
2018-09-16 00:00:05 +03:00
Aleksey Kladov
e69ff21207
kill old module_map
2018-09-16 00:00:05 +03:00
Aleksey Kladov
3ebeb0db8d
move readonly source to module tree descr
2018-09-16 00:00:05 +03:00
Aleksey Kladov
58674dc3c4
ModuleTreeDescriptor
2018-09-16 00:00:05 +03:00
Aleksey Kladov
d59413c895
yet another db api
2018-09-16 00:00:05 +03:00
Aleksey Kladov
0d7b1e442d
minor
2018-09-16 00:00:05 +03:00
Aleksey Kladov
47be3a3a24
renames
2018-09-16 00:00:05 +03:00
Aleksey Kladov
8c737255ff
use salsa for new module map
2018-09-16 00:00:05 +03:00
Aleksey Kladov
60fdfec327
eager invalidation
2018-09-16 00:00:05 +03:00
Aleksey Kladov
cecc7ad5b2
be generic over data
2018-09-16 00:00:05 +03:00
Aleksey Kladov
8cf9c27196
generic salsa algo
2018-09-16 00:00:05 +03:00
Aleksey Kladov
0e493160c0
store params in the graph
2018-09-16 00:00:05 +03:00
Aleksey Kladov
907d44a751
any-cache
2018-09-16 00:00:05 +03:00
Aleksey Kladov
dbdf72e2e2
fix dep tracking
2018-09-16 00:00:05 +03:00
Aleksey Kladov
c81d0d51bf
add deps tracking
2018-09-16 00:00:05 +03:00
Aleksey Kladov
db14b4270c
Add simplisitc global modification caching
2018-09-16 00:00:05 +03:00
Aleksey Kladov
3ae3b3eb06
initial query tracing
2018-09-16 00:00:05 +03:00
Aleksey Kladov
99d02fe583
start query-based modules
2018-09-16 00:00:05 +03:00
bors[bot]
2a56b5c4f0
Merge #69
...
69: Incremental reparsing for single tokens r=matklad a=darksv
Implement incremental reparsing for `WHITESPACE`, `COMMENT`, `DOC_COMMENT`, `IDENT`, `STRING` and `RAW_STRING`. This allows to avoid reparsing whole blocks when a change was made only within these tokens.
Co-authored-by: darksv <darek969-12@o2.pl>
2018-09-15 20:57:06 +00:00
darksv
ab00639032
independent tests for incremental reparsing of blocks and leaves
2018-09-15 17:05:08 +02:00
darksv
46cee0415c
move reparsing tests
2018-09-15 14:35:30 +02:00
darksv
16ad5384f0
commit missing file
2018-09-15 13:42:10 +02:00
darksv
a29211918b
create separated mod for reparsing functionality
2018-09-15 13:35:55 +02:00
darksv
d825cffe3b
adjust trailing newline
2018-09-14 23:45:19 +02:00
darksv
ecbfe68bf4
add missing files with inline tests
2018-09-14 23:33:29 +02:00
darksv
100968b689
Support for unions
2018-09-14 22:51:12 +02:00
darksv
bc94bf95ce
correctly handle IDENTs when changed to contextual keywords
2018-09-14 19:26:48 +02:00
darksv
c300135322
create leaf directly without calling the parser
2018-09-14 19:23:10 +02:00
darksv
4356240fa4
Incremental reparsing for single tokens (WHITESPACE, COMMENT, DOC_COMMENT, IDENT, STRING, RAW_STRING)
2018-09-13 23:25:05 +02:00
Aleksey Kladov
b6f8037a6f
don't get stuck in slice patterns
2018-09-12 11:26:52 +03:00
Aleksey Kladov
ccc75675b6
correctly setup path-map for fs-changes
2018-09-12 11:19:19 +03:00
bors[bot]
e240360ee2
Merge #68
...
68: Implement incremental reparsing for remaining braced blocks r=matklad a=darksv
Fixes #66
Co-authored-by: darksv <darek969-12@o2.pl>
2018-09-11 07:32:36 +00:00
darksv
d0cfeb4f16
Do not reparse token tree when it is not delimited by braces
2018-09-10 23:21:16 +02:00
darksv
64d07c1bd4
Implement reparsing for remaining blocks
2018-09-10 20:14:09 +02:00
Aleksey Kladov
505895a25f
store file rsovler
2018-09-10 12:57:40 +03:00
bors[bot]
4f64709666
Merge #65
...
65: simplify r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2018-09-08 16:24:24 +00:00
Aleksey Kladov
f19a82beac
simplify
2018-09-08 19:16:11 +03:00
Aleksey Kladov
a5c333c3ed
Fix yet another parser infinite loop
...
This commit is an example of fixing a common parser error: infinite
loop due to error recovery.
This error typically happens when we parse a list of items and fail to
parse a specific item at the current position.
One choices is to skip a token and try to parse a list item at the
next position. This is a good, but not universal, default. When
parsing a list of arguments in a function call, you, for example,
don't want to skip over `fn`, because it's most likely that it is a
function declaration, and not a mistyped arg:
```
fn foo() {
quux(1, 2
fn bar() {
}
```
Another choice is to bail out of the loop immediately, but it isn't
perfect either: sometimes skipping over garbage helps:
```
quux(1, foo:, 92) // should skip over `:`, b/c that's part of `foo::bar`
```
In general, parser tries to balance these two cases, though we don't
have a definitive strategy yet.
However, if the parser accidentally neither skips over a token, nor
breaks out of the loop, then it becomes stuck in the loop infinitely
(there's an internal counter to self-check this situation and panic
though), and that's exactly what is demonstrated by the test.
To fix such situation, first of all, add the test case to tests/data/parser/{err,fuzz-failures}.
Then, run
```
RUST_BACKTRACE=short cargo test --package libsyntax2
````
to verify that parser indeed panics, and to get an idea what grammar
production is the culprit (look for `_list` functions!).
In this case, I see
```
10: libsyntax2::grammar::expressions::atom::match_arm_list
at crates/libsyntax2/src/grammar/expressions/atom.rs:309
```
and that's look like it might be a culprit. I verify it by adding
`eprintln!("loopy {:?}", p.current());` and indeed I see that this is
printed repeatedly.
Diagnosing this a bit shows that the problem is that
`pattern::pattern` function does not consume anything if the next
token is `let`. That is a good default to make cases like
```
let
let foo = 92;
```
where the user hasn't typed the pattern yet, to parse in a reasonable
they correctly.
For match arms, pretty much the single thing we expect is a pattern,
so, for a fix, I introduce a special variant of pattern that does not
do recovery.
2018-09-08 19:10:40 +03:00
Aleksey Kladov
3ab9f4ad7f
Add fuzz failures dir
2018-09-08 18:42:59 +03:00
Aleksey Kladov
ba4a697d8c
move fuzz-invariants to the library
2018-09-08 18:34:41 +03:00
Pascal Hertleif
a37cd5ad43
Add trivial fuzzer for parser
...
As described in #61 , fuzz testing some parts of this would be ~~fun~~
helpful. So, I started with the most trivial fuzzer I could think of:
Put random stuff into File::parse and see what happens.
To speed things up, I also did
cp src/**/*.rs fuzz/corpus/parser/
in the `crates/libsyntax2/` directory (running the fuzzer once will
generate the necessary directories).
2018-09-08 16:55:53 +02:00
Aleksey Kladov
df05c5c3e2
Don't overflow when limiting symbol search
2018-09-08 15:39:28 +03:00
Aleksey Kladov
7daaddb2ac
Some abstraction around workers
2018-09-08 13:15:01 +03:00
Aleksey Kladov
326ffcefe0
Deal with deadlocks in a more principaled way
2018-09-08 12:36:02 +03:00
Aleksey Kladov
d9ccebd913
fix deadlock
2018-09-08 12:08:46 +03:00
Aleksey Kladov
f48b9d9be7
Fix block structure in enums
2018-09-08 10:55:09 +03:00
Aleksey Kladov
749907d330
simplify
2018-09-08 10:38:53 +03:00
Aleksey Kladov
febbc9acdd
Don't get stuck in tuple exprs
2018-09-08 10:35:05 +03:00
Aleksey Kladov
a0a347eac9
Don't get stuck in macros
2018-09-08 10:28:53 +03:00
Aleksey Kladov
bd3a26493f
fix stuck parser
2018-09-08 10:13:32 +03:00
Aleksey Kladov
44334f6f56
fix labled expressions
2018-09-08 09:18:42 +03:00
Aleksey Kladov
127814d9a7
nested mod completion
2018-09-08 01:35:20 +03:00
Aleksey Kladov
ff1c82216c
Remove dyn dispatch
2018-09-08 01:16:07 +03:00
Aleksey Kladov
fcfda94664
Separete API from IMPL
...
Looks like there's a rule of thumb: don't call API functions from an
implementation! In this case, following this rule of thumb saves us an
Arc-bump!
2018-09-07 22:05:05 +03:00
Zac Winter
518cc87496
Moved TokenSet into it's own file.
2018-09-06 21:57:04 +08:00
Aleksey Kladov
751562d2f7
better introduce
2018-09-06 01:19:24 +03:00
Aleksey Kladov
bb64edf8ba
introduce variable
2018-09-06 00:59:07 +03:00
Aleksey Kladov
47e8b80e9b
use correct workdir for the server
2018-09-05 21:38:43 +03:00
Aleksey Kladov
669eabe892
even less hacks
2018-09-05 20:22:52 +03:00
Aleksey Kladov
d0e22d7578
less hacky paths
2018-09-05 18:27:44 +03:00
bors[bot]
ad451686a8
Merge #56
...
56: Unify lookahead naming between parser and lexer. r=matklad a=zachlute
Resolves Issue #26 .
I wanted to play around with libsyntax2, and fixing a random issue seemed like a good way to mess around in the code.
This PR mostly does what's suggested in that issue. I elected to go with `at` and `at_str` instead of trying to do any fancy overloading shenanigans, because...uh, well, frankly I don't really know how to do any fancy overloading shenanigans. The only really questionable bit is `nth_is_p`, which could also have potentially been named `nth_at_p`, but `is` seemed more apropos.
I also added simple tests for `Ptr` so I could be less terrified I broke something.
Comments and criticisms very welcome. I'm still pretty new to Rust.
Co-authored-by: Zach Lute <zach.lute@gmail.com>
2018-09-05 15:07:17 +00:00
Aleksey Kladov
649f7faf7d
fix tests on windows
2018-09-05 15:03:27 +01:00
Zach Lute
d21fead150
Added tests for Ptr.
2018-09-04 23:26:11 -07:00
Zach Lute
af0ae9ee04
Updated Ptr methods to better match Parser method names.
2018-09-04 22:56:16 -07:00
Aleksey Kladov
f87771092c
switch to rayon threadpool
2018-09-04 20:43:37 +03:00
Aleksey Kladov
8b0210d233
simplify
2018-09-04 19:00:01 +03:00
Aleksey Kladov
8ed06d766f
better extend selection
2018-09-04 12:48:39 +03:00
Aleksey Kladov
e44a6bcc82
for types in bounds
2018-09-04 12:25:23 +03:00
Aleksey Kladov
3a017aaa52
dont change readonly files
2018-09-04 11:40:45 +03:00
Aleksey Kladov
a668f703fa
micro-optimize
2018-09-04 05:09:39 +03:00
Aleksey Kladov
294534abc7
accidentally quadratic
2018-09-04 05:04:55 +03:00
Aleksey Kladov
4df965a002
work
2018-09-04 04:13:22 +03:00
Aleksey Kladov
c3e28f0646
extern blocks
2018-09-04 00:49:21 +03:00
Aleksey Kladov
952da31f44
switch to internal feedback
2018-09-03 23:32:42 +03:00
Aleksey Kladov
971054e4d0
fix the test
2018-09-03 21:51:17 +03:00
Aleksey Kladov
f590635f57
faster text len
2018-09-03 21:48:26 +03:00
Aleksey Kladov
5ba645c009
index libraies off the main thread
2018-09-03 21:26:59 +03:00
Aleksey Kladov
47cbaeba6f
Index deps
2018-09-03 21:03:37 +03:00
Aleksey Kladov
b04c14d4ad
dispatch acros roots
2018-09-03 19:46:30 +03:00
Aleksey Kladov
2f2feef9af
completion for trait params
2018-09-03 15:46:14 +03:00
Aleksey Kladov
4798a89a12
Complete params
2018-09-03 15:10:06 +03:00
Aleksey Kladov
58480b9190
method call scope
2018-09-03 02:01:43 +03:00
Aleksey Kladov
fdd282ee0c
improve test
2018-09-03 01:52:59 +03:00
Aleksey Kladov
23303cd0f8
match scope
2018-09-03 01:51:46 +03:00
Aleksey Kladov
83e2ab434c
store file id inside symbol
2018-09-02 23:36:23 +03:00
Aleksey Kladov
a5e319ec7e
Store symbols separately from file data
2018-09-02 23:09:47 +03:00
Aleksey Kladov
440dc41dd8
Add source root
2018-09-02 22:51:59 +03:00
Aleksey Kladov
e98d8cd255
nail down runnables
2018-09-02 16:36:03 +03:00
Aleksey Kladov
1329dd4e28
Avoid clones
2018-09-02 15:18:43 +03:00
Aleksey Kladov
80be61ed78
project model
2018-09-02 14:46:15 +03:00
Aleksey Kladov
7fad13de73
store messages in tests
2018-09-02 12:34:06 +03:00
Aleksey Kladov
d752455637
introduce project model
2018-09-02 11:37:57 +03:00
Aleksey Kladov
541170420b
Add an integration test
2018-09-01 20:21:11 +03:00
Aleksey Kladov
e8515fecd7
split lib
2018-09-01 18:16:08 +03:00
Aleksey Kladov
4268fbeaa1
simplify
2018-09-01 18:03:57 +03:00
Aleksey Kladov
8f1ce82753
move to gen-server impl
2018-09-01 17:40:45 +03:00
Aleksey Kladov
3588d6b2da
add gen_lsp_server
2018-09-01 16:18:02 +03:00
Aleksey Kladov
f5669dfc56
No self-imports in completion
2018-09-01 12:46:43 +03:00
Aleksey Kladov
2161a1689d
Type aliases to scope
2018-09-01 12:30:53 +03:00
Aleksey Kladov
f2772e29ae
add crate graph
2018-08-31 19:14:08 +03:00
Aleksey Kladov
7a5bc94774
complete self
2018-08-31 16:30:42 +03:00
Aleksey Kladov
cdb9b4cbf4
handle shadowing
2018-08-31 15:53:52 +03:00
Aleksey Kladov
78d60a549d
default method name to type name
2018-08-31 15:10:37 +03:00
Aleksey Kladov
05a9d42f54
tweak extend selection
2018-08-31 14:52:29 +03:00
Aleksey Kladov
8fc7f438c4
start item recovery
2018-08-31 13:35:48 +03:00
Aleksey Kladov
faebae74e4
fix tests
2018-08-31 12:13:02 +03:00
Aleksey Kladov
d999f4b568
cancelation
2018-08-31 12:04:33 +03:00
Aleksey Kladov
efa6a952b4
cancelation tokens
2018-08-31 10:27:38 +03:00
Aleksey Kladov
902df0fc05
add test
2018-08-30 21:42:23 +03:00
Aleksey Kladov
8f552ab352
break/continue completion
2018-08-30 21:32:12 +03:00
Aleksey Kladov
80ab3433d3
complete imports
2018-08-30 20:37:33 +03:00
Aleksey Kladov
49e14a99ed
Complete types
2018-08-30 20:03:18 +03:00
Aleksey Kladov
9fcebbc512
subscriptions
2018-08-30 16:27:09 +03:00
Aleksey Kladov
7570d85869
loop scope
2018-08-30 16:05:49 +03:00
Aleksey Kladov
c2c64145cb
move
2018-08-30 13:12:49 +03:00
Aleksey Kladov
1f2fb4e27f
move
2018-08-30 12:52:21 +03:00
Aleksey Kladov
0d6d74e78e
minor
2018-08-30 12:34:31 +03:00
Aleksey Kladov
7d95d38ecb
fix join lines selection
2018-08-29 18:35:28 +03:00
Aleksey Kladov
09ea0ca7e5
rename world -> analysis impl
2018-08-29 18:23:57 +03:00
Aleksey Kladov
0f968ee430
minor
2018-08-29 18:12:28 +03:00
Aleksey Kladov
4dd4571bfe
minor
2018-08-29 18:09:08 +03:00
Aleksey Kladov
1baba9a2e2
Minor
2018-08-29 18:07:56 +03:00
Aleksey Kladov
2e2c2e62eb
Remove dead code
2018-08-29 18:06:46 +03:00
Aleksey Kladov
fce6bc0acc
Make world private
2018-08-29 18:05:54 +03:00
Aleksey Kladov
8abf536343
Grand refactoring
2018-08-29 18:03:14 +03:00
Aleksey Kladov
754c034a81
fix tests
2018-08-29 11:15:51 +03:00
Aleksey Kladov
15f15d92eb
add impl works with lifetimes
2018-08-28 23:59:57 +03:00
Aleksey Kladov
ba02a55330
simplify
2018-08-28 22:58:02 +03:00
Aleksey Kladov
69eeae0c99
polish join
2018-08-28 22:52:51 +03:00
Aleksey Kladov
6effddb18c
fix comma list
2018-08-28 21:48:14 +03:00
Aleksey Kladov
e6ab53619b
be more careful with adding semis
2018-08-28 21:45:59 +03:00
Aleksey Kladov
f5de8212da
Tweak return completion
2018-08-28 21:31:34 +03:00
Aleksey Kladov
d351ae67a9
Smart return completion
2018-08-28 21:14:13 +03:00
Aleksey Kladov
2257c08cb1
Add ret type
2018-08-28 21:11:17 +03:00
Aleksey Kladov
b00a4d43ec
Dont diagnose inline mods
2018-08-28 20:29:36 +03:00
Aleksey Kladov
4c1f17af7d
completion snippets
2018-08-28 20:26:57 +03:00
Aleksey Kladov
b6c654e233
reread files from disk
2018-08-28 19:42:55 +03:00
Aleksey Kladov
dea6ed73fa
better pattern recovery
2018-08-28 19:35:09 +03:00
Aleksey Kladov
537ea620bb
complete items from module scope
2018-08-28 19:23:55 +03:00
Aleksey Kladov
d34588bf83
create module smartly
2018-08-28 18:22:59 +03:00
Aleksey Kladov
748a4cacd2
Reorganize tests
2018-08-28 14:47:12 +03:00
Aleksey Kladov
6c41a205a9
join any block
2018-08-28 14:21:37 +03:00
Aleksey Kladov
288c9d1ac6
Simplify API
2018-08-28 14:07:41 +03:00
Aleksey Kladov
7e74af3226
Avoid materializing strings
2018-08-28 14:06:30 +03:00
Aleksey Kladov
363f466627
tone down on eq typed
2018-08-28 11:17:08 +03:00
Aleksey Kladov
2fa90e736b
better recovery for exprs
2018-08-28 11:12:42 +03:00
Aleksey Kladov
13110f48e9
Log errors
2018-08-28 00:42:13 +03:00
Aleksey Kladov
8f5330cb07
More robust highlighting
2018-08-28 00:20:59 +03:00
Aleksey Kladov
422efe59af
you better run
2018-08-27 22:52:43 +03:00
Aleksey Kladov
5751815314
Add runnables
2018-08-27 22:03:19 +03:00
Aleksey Kladov
b79c8b6d8a
Fix error blocks
2018-08-27 21:10:02 +03:00
Aleksey Kladov
7f4b07a907
Refactor
2018-08-27 21:02:47 +03:00
Aleksey Kladov
aaca7d003b
move scopes to file
2018-08-27 20:58:38 +03:00
Aleksey Kladov
07cbb7d73d
Support if-let in scopes
2018-08-27 12:22:09 +03:00
Aleksey Kladov
c16530c988
visitor-less scopes
2018-08-27 10:12:28 +03:00
Aleksey Kladov
8b0298ce09
scopes
2018-08-27 10:01:31 +03:00
Aleksey Kladov
9b69c7df19
fix curly braces parsing
2018-08-26 19:04:44 +03:00
Aleksey Kladov
71722c047f
Simple scope completion
2018-08-26 12:51:45 +03:00
Aleksey Kladov
ac226021cf
scope based comletion
2018-08-26 12:09:28 +03:00
Aleksey Kladov
4c121bfa2f
extend selection to comments
2018-08-26 10:43:03 +03:00
Aleksey Kladov
a450142aca
fix stray curly
2018-08-26 09:12:18 +03:00
Aleksey Kladov
a48964c64d
switch to upstream fst
2018-08-25 23:50:16 +03:00
Aleksey Kladov
367e523442
Require semi after exprs
2018-08-25 16:04:47 +03:00
Aleksey Kladov
a80c07bdff
Avoid massacaring errors
2018-08-25 15:12:17 +03:00
Aleksey Kladov
c3e5987c43
incremental reparse
2018-08-25 14:45:17 +03:00
Aleksey Kladov
5211e7d977
move
2018-08-25 14:30:54 +03:00
Aleksey Kladov
2d41bc3e6c
rename
2018-08-25 14:26:34 +03:00
Aleksey Kladov
da329c2e53
more incremental work
2018-08-25 13:57:13 +03:00
Aleksey Kladov
19d933ba38
join lines works for lambdas
2018-08-25 13:42:40 +03:00
Aleksey Kladov
838820ad98
fix assertione error on block parsing
2018-08-25 13:21:43 +03:00
Aleksey Kladov
fed5727ea2
start incremental reparse
2018-08-25 13:17:54 +03:00
Aleksey Kladov
32c8ea9307
Move atom edit to libsyntax2
2018-08-25 12:44:26 +03:00
Aleksey Kladov
87cd57d56a
Refactor
2018-08-25 12:10:35 +03:00
Aleksey Kladov
a44428fc79
kill more reexports
2018-08-25 11:48:59 +03:00
Aleksey Kladov
70333c8edf
remove reesports
2018-08-25 11:47:24 +03:00
Aleksey Kladov
220d285b4a
rename ParsedFile -> File
2018-08-25 11:44:58 +03:00
Aleksey Kladov
cf278ed3bf
rename file -> root
2018-08-25 11:44:17 +03:00
Aleksey Kladov
9fae494a8d
Move ParsedFile to top
2018-08-25 11:40:17 +03:00
Aleksey Kladov
f104458d45
parameter parsing does not destroy blocks
2018-08-24 20:50:37 +03:00
Aleksey Kladov
b0aac1ca98
rename tests
2018-08-24 19:35:20 +03:00
Aleksey Kladov
7edab6ae6b
nodes for blocks
2018-08-24 19:27:30 +03:00
Aleksey Kladov
6cade3f6d8
Runnig tests somehow
2018-08-24 13:41:25 +03:00
Aleksey Kladov
89e56c364f
Labeled expressions
2018-08-24 11:45:50 +03:00
Aleksey Kladov
719710a132
break&continue
2018-08-24 11:21:13 +03:00
Aleksey Kladov
a66c94af1b
renames
2018-08-24 02:14:10 +03:00
Aleksey Kladov
dc40f1298a
better self-types
2018-08-24 01:19:38 +03:00
Aleksey Kladov
cf7d4a2a24
Simplify
2018-08-24 00:48:10 +03:00
Aleksey Kladov
dd64a155e9
rename
2018-08-24 00:16:29 +03:00
Aleksey Kladov
f47f58ffe5
better join-lines
2018-08-24 00:13:16 +03:00
Aleksey Kladov
8ad586a44e
JoinLines frontend
2018-08-23 22:14:51 +03:00
Aleksey Kladov
18918769ba
Smarter join lines
2018-08-23 21:38:25 +03:00
Aleksey Kladov
6dcf87fb5f
Start join-lines
2018-08-23 20:55:23 +03:00
Aleksey Kladov
ec70617564
byte literals
2018-08-23 20:04:13 +03:00
Aleksey Kladov
a077533513
Allow arbitrary self-types
2018-08-23 19:07:33 +03:00
Aleksey Kladov
8d82d1551e
Extend add impl
2018-08-22 19:06:30 +03:00
Aleksey Kladov
147578f0fe
add impl initial
2018-08-22 18:05:43 +03:00
Aleksey Kladov
69a524fbef
dedupe
2018-08-22 17:01:51 +03:00
Aleksey Kladov
8e3bec11eb
TypeParamList Owner
2018-08-22 16:46:42 +03:00
Aleksey Kladov
55896aedb1
minor
2018-08-22 15:01:34 +03:00
Aleksey Kladov
a4f140b0f3
no escape
2018-08-22 13:22:06 +03:00
Aleksey Kladov
e8dfb92641
Simplify
2018-08-22 12:58:34 +03:00
Aleksey Kladov
641659d5a8
Smarter extend selection
2018-08-22 11:56:36 +03:00
Aleksey Kladov
9909875bfe
parent module request
2018-08-22 10:53:48 +03:00
Aleksey Kladov
ecc9df5f00
simpler update
2018-08-21 22:24:59 +03:00
Aleksey Kladov
b937262c9b
Module map implementation
2018-08-21 18:30:10 +03:00
Aleksey Kladov
4d8be26584
refactor
2018-08-18 12:42:28 +03:00
Aleksey Kladov
a5eeef0eee
better char lexing
2018-08-18 12:13:34 +03:00
Aleksey Kladov
c7b1be6be3
Owned
2018-08-17 22:03:55 +03:00
Aleksey Kladov
d3c90ded2b
Borrowed AST
2018-08-17 22:00:13 +03:00
Aleksey Kladov
70097504f7
hide root
2018-08-17 21:10:55 +03:00
Aleksey Kladov
ed7ae78c6f
ServerWorld
2018-08-17 19:54:08 +03:00
Aleksey Kladov
41570f60bf
extend module resolve to mod.rs
2018-08-17 16:04:34 +03:00
Aleksey Kladov
081c16c776
initial mod resolve
2018-08-17 15:37:17 +03:00
Aleksey Kladov
55e87e0b74
mod resolve work
2018-08-17 00:18:14 +03:00
Aleksey Kladov
6a3f819f79
move smol_str to a separare repo
2018-08-16 23:40:48 +03:00
Aleksey Kladov
e0a43a159d
vscode moves cursor
2018-08-16 13:46:31 +03:00
Aleksey Kladov
eda52cbc34
allow field attrs
2018-08-16 13:20:59 +03:00
Aleksey Kladov
a5515d9d6f
Add derive handles cursor
2018-08-16 13:11:20 +03:00
Aleksey Kladov
7094291573
tt-attrs
2018-08-16 12:51:40 +03:00
Aleksey Kladov
1193c5f829
dead code
2018-08-16 11:08:41 +03:00
Aleksey Kladov
c631b585a7
matching brace
2018-08-16 00:23:22 +03:00
Aleksey Kladov
aa0d344581
Edits with cursors
2018-08-15 23:24:20 +03:00
Aleksey Kladov
a7d31b55a4
Simplify walk
2018-08-15 21:25:29 +03:00
Aleksey Kladov
9f6cf42c5f
Switch to file ids
2018-08-15 17:24:20 +03:00
Aleksey Kladov
109658332a
Support raw strings in lexer
2018-08-14 15:03:27 +03:00
Aleksey Kladov
199e3b73c7
fields are part of the structure
2018-08-14 14:45:56 +03:00
Aleksey Kladov
1141d448d9
Add derive intention
2018-08-14 13:33:44 +03:00
Aleksey Kladov
5953a348bd
Less hackish impl structure
2018-08-14 12:38:20 +03:00
Aleksey Kladov
de02d2891e
full range expr
2018-08-14 11:46:46 +03:00
Aleksey Kladov
2b828c68e8
separete structure from symbols
2018-08-14 11:20:09 +03:00
Aleksey Kladov
49ab441024
Qualified paths
2018-08-13 23:54:00 +03:00
Aleksey Kladov
d9e86e574a
Use rayon for parallel indexing
2018-08-13 19:28:34 +03:00
Aleksey Kladov
439e0fd32e
Fix some more bugs
2018-08-13 18:46:43 +03:00
Aleksey Kladov
7d0c9cf546
Optional patterns in trait methods
2018-08-13 18:40:47 +03:00
Aleksey Kladov
c146331b1c
rename
2018-08-13 18:36:16 +03:00
Aleksey Kladov
1d95f34e9a
More renames
2018-08-13 18:34:02 +03:00
Aleksey Kladov
d642c48616
forgotten test
2018-08-13 18:31:28 +03:00
Aleksey Kladov
51f7f937a5
Safer errors
2018-08-13 18:30:56 +03:00
Aleksey Kladov
c1a7b72fb7
renames
2018-08-13 18:27:26 +03:00
Aleksey Kladov
9149fd2c0c
Fix some parser bugs
2018-08-13 18:24:17 +03:00
Aleksey Kladov
d1eceefeb8
dyn type
2018-08-13 17:42:43 +03:00
Aleksey Kladov
5a56ac4b72
Better limiting
2018-08-13 17:19:27 +03:00
Aleksey Kladov
8ae56fa6d0
Stupid goto definition
2018-08-13 16:35:17 +03:00
Aleksey Kladov
7fc91f41d8
Generalize query
2018-08-13 16:07:05 +03:00
Aleksey Kladov
0568e76406
smol debug
2018-08-13 15:44:51 +03:00
Aleksey Kladov
d19f3ac834
workspace symbols
2018-08-13 15:35:53 +03:00
Aleksey Kladov
133d001d82
world symbols
2018-08-13 15:10:20 +03:00
Aleksey Kladov
ed2ac17133
smol_str to a crate
2018-08-13 14:24:22 +03:00
Aleksey Kladov
18486a02fa
indexing infra
2018-08-13 13:46:05 +03:00
Aleksey Kladov
be742a5877
Apply code actions
2018-08-13 02:38:34 +03:00
Aleksey Kladov
25aebb5225
Refctor
2018-08-13 00:09:30 +03:00
Aleksey Kladov
535bd7ccf7
remove useless loop
2018-08-12 22:23:44 +03:00
Aleksey Kladov
b518fd0ef9
Sans IO dispatch
2018-08-12 22:12:51 +03:00
Aleksey Kladov
1962369806
more modules
2018-08-12 22:08:14 +03:00
Aleksey Kladov
acd7552698
Simplify
2018-08-12 21:47:27 +03:00
Aleksey Kladov
58c3370819
Simplify
2018-08-12 21:45:03 +03:00
Aleksey Kladov
8dad14b5cd
Convert Thunk to Task
2018-08-12 21:34:17 +03:00
Aleksey Kladov
23c06db9c2
Half of code-actions
2018-08-12 21:02:56 +03:00
Aleksey Kladov
66be735aa9
flip comma
2018-08-12 18:50:16 +03:00
Aleksey Kladov
56aa6e20e0
More symbols
2018-08-11 16:20:37 +03:00
Aleksey Kladov
ce06a9ddcb
Switch to upstream langserver-types
2018-08-11 16:05:00 +03:00
Aleksey Kladov
f2291d6a76
doc symbols
2018-08-11 14:44:12 +03:00
Aleksey Kladov
7afd84febc
visitor
2018-08-11 12:28:59 +03:00
Aleksey Kladov
d5119133fc
heck
2018-08-11 11:03:22 +03:00
Aleksey Kladov
78f41ea707
more renames
2018-08-11 10:56:40 +03:00
Aleksey Kladov
2e971cdcbb
Use dict for AST
2018-08-11 10:11:58 +03:00
Aleksey Kladov
e69c70e2a2
ENUM_ITEM -> ENUM
2018-08-11 10:05:26 +03:00
Aleksey Kladov
7698d37fa4
STRUCT_ITEM -> STRUCT
2018-08-11 10:04:47 +03:00
Aleksey Kladov
ce898183b8
Simplify tests
2018-08-11 10:03:03 +03:00
Aleksey Kladov
b18d2882f4
Generate accessors
2018-08-11 09:55:32 +03:00
Aleksey Kladov
7581984601
bump ron
2018-08-11 09:38:27 +03:00
Aleksey Kladov
35b59bb438
simplify
2018-08-11 08:56:13 +03:00
Aleksey Kladov
f99551f46b
reorganize
2018-08-11 01:04:09 +03:00
Aleksey Kladov
9863b9161d
decorations
2018-08-11 00:55:32 +03:00
Aleksey Kladov
836e0c1863
simplify
2018-08-11 00:12:31 +03:00
Aleksey Kladov
46e4232cc6
simplify bouds
2018-08-11 00:01:37 +03:00
Aleksey Kladov
52de08330f
dedupe
2018-08-10 23:56:19 +03:00
Aleksey Kladov
bf42a75f1e
dedupe
2018-08-10 23:45:35 +03:00
Aleksey Kladov
36d922c87d
diagnostics
2018-08-10 23:30:11 +03:00
Aleksey Kladov
5896cd51de
Cleanup log messages
2018-08-10 22:55:42 +03:00
Aleksey Kladov
7c67612b8a
organizize
2018-08-10 22:33:29 +03:00