Commit Graph

100 Commits

Author SHA1 Message Date
Aleksey Kladov
33965f0f3e fix renaming of modules 2019-09-05 21:36:40 +03:00
Aleksey Kladov
69bbe79c50 implement feature flags 2019-08-22 15:07:31 +03:00
Aleksey Kladov
343463c824 implement durability 2019-08-15 15:27:00 +03:00
Kirill Bulatov
dbbb0beb3e Make Analysis api cancellable 2019-07-25 20:22:41 +03:00
Kirill Bulatov
09c7c86696 Resolve types on the server 2019-07-21 23:44:37 +03:00
Kirill Bulatov
24784c60df Code review fixes 2019-07-21 20:51:27 +03:00
Kirill Bulatov
201b344f2b Refactor server api 2019-07-20 23:45:26 +03:00
Aleksey Kladov
f1abc7bdc6 migrate ra_ide_api to the new rowan 2019-07-19 13:16:25 +03:00
Aleksey Kladov
deab4caa7b make Parse fields private
this is in preparation for the new rowan API
2019-07-12 19:41:13 +03:00
Aleksey Kladov
1834bae5b8 allow rustfmt to reorder imports
This wasn't a right decision in the first place, the feature flag was
broken in the last rustfmt release, and syntax highlighting of imports
is more important anyway
2019-07-04 23:09:09 +03:00
Aleksey Kladov
d70520eb38 print memory usage for queries 2019-06-30 14:49:45 +03:00
Aleksey Kladov
18a1e092e9 Move memory usage statistics to ra_prof 2019-06-30 13:30:17 +03:00
Aleksey Kladov
6314e62cfb add analysis-bench to benchmark incremental analysis
Can be used like this:

```
$ cargo run --release -p ra_cli -- \
  analysis-bench ../chalk/ \
  --complete ../chalk/chalk-engine/src/logic.rs:94:0

loading: 225.970093ms

from scratch:   8.492373325s
no change:      445.265µs
trivial change: 95.631242ms
```

Or like this:

```
$ cargo run --release -p ra_cli -- \
  analysis-bench ../chalk/ \
  --highlight ../chalk/chalk-engine/src/logic.rs

loading: 209.873484ms

from scratch:   9.504916942s
no change:      7.731119ms
trivial change: 124.984039ms
```

"from scratch" includes initial analysis of the relevant bits of the
project

"no change" just asks the same question for the second time. It
measures overhead on assembling the answer outside of salsa.

"trivial change" doesn't do an actual salsa change, it just advances
the revision. This test how fast is salsa at validating things.
2019-06-16 19:45:05 +03:00
Aleksey Kladov
b0be4207d0 reuse AnalysisHost in batch analysis 2019-06-15 16:29:23 +03:00
Aleksey Kladov
fed52706de make LRU cache configurable 2019-06-12 13:36:24 +03:00
Edwin Cheng
d46278d320 Remove node function in NavTarget 2019-06-08 22:27:11 +08:00
Aleksey Kladov
61e1474ab3 fix typos in mbe tests 2019-05-28 18:46:11 +03:00
Pascal Hertleif
2b200f6e1a
Disable broken struct field rainbowing 2019-05-27 11:26:35 +02:00
Pascal Hertleif
43d5a49653
More clever highlighting, incl draft for structs 2019-05-27 11:26:35 +02:00
Aleksey Kladov
c6e905a79f Colorize Rust code as HTML 2019-05-25 13:42:34 +03:00
Laurențiu Nicola
444e52e519 Move NameRef classification logic out of reference_definition 2019-05-23 12:32:47 +03:00
kjeremy
7125192c1e Basic resolution for ADT 2019-04-23 14:32:47 -04:00
Ville Penttinen
bd6ddfcdde Make display modules private 2019-04-09 14:45:05 +03:00
Ville Penttinen
7821c56be7 Move structure to display/structure 2019-04-09 14:45:05 +03:00
Ville Penttinen
027d4d229d Move navigation_target to display/navigation_target 2019-04-09 14:45:05 +03:00
Ville Penttinen
7ba22f1c19 Move FunctionSignature to display, remove write_joined
write_joined is replaced with `join_to_string::join` which provides the
necessary functionality.
2019-04-09 14:45:05 +03:00
Ville Penttinen
0e49abb7fb Refactor CallInfo function signatures to new FunctionSignature type
This is used by CallInfo to create a pretty printed function signature that can
be used with completions and other places as well.
2019-04-09 14:45:04 +03:00
Sergey Parilin
36cb58f76d structure moved to ra_ide_api
ra_ide_api_light removed completely
2019-03-25 11:41:21 +03:00
Ville Penttinen
4d26bae46d Rename source_edit to source_file_edit to match file_system_edit 2019-03-25 09:13:58 +02:00
Ville Penttinen
b92fcbc956 Further improvements to the SourceChange convenience methods
Rename system_edit to file_system_edit, add more documentation, add
source_file_edit_from to create a SourceChange from `FileId` and `TextEdit`.
2019-03-25 09:03:10 +02:00
Ville Penttinen
22e1c7a112 Add convenience functions to SourceChange for creating single edits 2019-03-24 22:53:41 +02:00
Wilco Kusee
a3711e08dc Move highlighting and matching_brace 2019-03-23 17:34:49 +01:00
Wilco Kusee
a656b891fb Remove LocalEdit usage 2019-03-23 17:00:49 +01:00
Wilco Kusee
0c15deac76 Move typing to ra_ide_api 2019-03-23 12:11:46 +01:00
Wilco Kusee
01bca7114c Simplify changes and fix tests 2019-03-22 17:12:32 +01:00
Wilco Kusee
9bd8336c51 Remove LocalEdit usage 2019-03-22 17:12:32 +01:00
Wilco Kusee
58e77660de Move join_lines to ra_ide_api 2019-03-22 17:12:31 +01:00
Sergey Parilin
47c501bcfb Move folding_ranges to ra_ide_api 2019-03-22 16:31:21 +03:00
Sergey Parilin
fda70badf8 line_index and line_index_utils moved to ra_ide_api 2019-03-22 15:24:43 +03:00
Aleksey Kladov
3eb56f7a6a introduce Analysis::from_single_file 2019-03-20 23:38:59 +03:00
Ville Penttinen
16ecd276f0 Implement syntax tree support for syntax inside string
This allows us to select a string or portions of it and try parsing it as rust
syntax. This is mostly helpful when developing tests where the test
itself contains some rust syntax as a string.
2019-03-04 09:02:01 +02:00
Ville Penttinen
ac52d9a1f1 Add optional range parameter to SyntaxTreeParams
When range is provided, instead of showing the syntax for the whole file, we'll
show the syntax tree for the given range.
2019-03-03 19:49:50 +02:00
Ville Penttinen
6f5fd6c9de Add new type HoverResult to contain the results of hovering
This makes testing hovers easier as well as allows us to do more things with the
results if needed.
2019-02-26 19:30:17 +02:00
Aleksey Kladov
ef442b8682 Assign IDs to assists 2019-02-24 14:00:00 +03:00
Aleksey Kladov
f7f99af0a6 kill utils module 2019-02-21 15:57:40 +03:00
Ville Penttinen
85a6bf3424 Refactor find_all_refs to return ReferenceSearchResult 2019-02-17 13:40:43 +02:00
Aleksey Kladov
2d131d63f9 document design guideline 2019-02-16 15:15:52 +03:00
Florian Diebold
3a9934e2c3 Keep track of crate edition 2019-02-13 20:10:46 +01:00
Pascal Hertleif
4fd3613434 Fix some typos 2019-02-12 15:02:57 +01:00
Aleksey Kladov
12e3b4c70b reformat the world 2019-02-08 14:49:43 +03:00