Commit graph

664 commits

Author SHA1 Message Date
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
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