Ekaterina Babshukova
88ff88d318
use Lazy, some fixes
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
19fbf2c16b
remove unreachable!()
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
835173d065
replace trait by a bunch of functions
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
d26d0ada50
restructure a bit
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
121aa35f12
return Declaration from classify_name_ref
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
d6ae1b5f0f
refactor name_ref_kind.rs
2019-10-22 23:47:31 +03:00
Ekaterina Babshukova
11577288c2
initial classify_name
2019-10-22 23:47:31 +03:00
Aleksey Kladov
6503add6e3
restore coloring of attributes
2019-10-08 14:52:03 +03:00
Alexander Andreev
fdbd6bb11a
Added test for check doc strings in crates.
...
#1856
2019-09-30 11:58:53 +03:00
Florian Diebold
828d60574f
Refactor a bit to prepare for resolving trait assoc items
2019-09-17 19:47:45 +02:00
Aleksey Kladov
114a1b878e
rename AdtDef -> Adt
2019-09-13 00:34:52 +03:00
Aleksey Kladov
45117c6388
make various enums "inherit" from AdtDef
2019-09-13 00:10:16 +03:00
Aleksey Kladov
5b18a4eef9
rename struct -> record, pos -> tuple
2019-08-23 16:59:50 +03:00
cynecx
5534167f58
Fix syntax-highlighting for fields (NAMED_FIELD_DEF
)
2019-08-22 00:39:18 +02:00
Aleksey Kladov
f3bdbec1b6
rename range -> text_range
2019-07-20 12:58:27 +03:00
Aleksey Kladov
191a6ba330
convenience api
2019-07-19 19:05:34 +03:00
Aleksey Kladov
f9d9e0a1f7
several highlighting cleanups
...
* make stuff more type-safe by using `BindPat` instead of just `Pat`
* don't add `mut` into binding hash
* reset shadow counter when we enter a function
2019-07-19 16:09:32 +03:00
Aleksey Kladov
f1abc7bdc6
migrate ra_ide_api to the new rowan
2019-07-19 13:16:25 +03:00
bors[bot]
abe72424a6
Merge #1547
...
1547: cleanup imports r=matklad a=matklad
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-07-18 17:17:01 +00:00
Aleksey Kladov
1edec77e58
cleanup imports
2019-07-18 20:16:33 +03:00
Aleksey Kladov
2c4c233ba8
prettier colors
2019-07-18 19:57:13 +03:00
Ekaterina Babshukova
4abe03879b
highlight mutable variables differently
2019-07-18 18:52:50 +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
b6a854e161
update ra_ide_api to use builtins
2019-05-30 16:10:07 +03:00
Laurențiu Nicola
b1e59cb095
Highlight primitive types
2019-05-29 21:54:22 +03:00
bors[bot]
7a1cae59ac
Merge #1337
...
1337: Move syntax errors our of syntax tree r=matklad a=matklad
I am not really sure if it's a good idea, but `SyntaxError` do not really belong to a `SyntaxTree`. So let's just store them on the side?
Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-05-29 06:40:39 +00:00
Laurențiu Nicola
9146a64386
Highlight type names correctly
2019-05-29 08:30:53 +03:00
Aleksey Kladov
61e1474ab3
fix typos in mbe tests
2019-05-28 18:46:11 +03:00
Pascal Hertleif
5abcca516d
make it build again
2019-05-27 11:26:35 +02: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
Pascal Hertleif
ed89b0638b
Hash based on binding name and shadow counter
2019-05-27 11:26:35 +02:00
Pascal Hertleif
5bf3e949e8
Semantic highlighting spike
...
Very simple approach: For each identifier, set the hash of the range
where it's defined as its 'id' and use it in the VSCode extension to
generate unique colors.
Thus, the generated colors are per-file. They are also quite fragile,
and I'm not entirely sure why. Looks like we need to make sure the
same ranges aren't overwritten by a later request?
2019-05-27 11:26:33 +02:00
Aleksey Kladov
c6e905a79f
Colorize Rust code as HTML
2019-05-25 13:42:34 +03:00
Aleksey Kladov
f6d2c3f9d5
profile highlighting
2019-05-23 21:19:54 +03:00
Aleksey Kladov
5d54aa6781
add union to code_model
2019-05-23 20:18:47 +03:00
Laurențiu Nicola
f1ec88cc56
Improve highlighting of name refs
2019-05-23 15:31:35 +03:00
Laurențiu Nicola
b08362f6d2
Address feedback
2019-05-21 16:28:10 +03:00
Laurențiu Nicola
9ade271a67
Use ThemeColor and add support for light themes
2019-05-21 14:19:08 +03:00
Sergey Parilin
993abedd77
apply T! macro where it is possible
2019-05-15 15:35:47 +03:00
Aleksey Kladov
9e213385c9
switch to new rowan
2019-04-01 12:06:24 +03:00
Wilco Kusee
a3711e08dc
Move highlighting and matching_brace
2019-03-23 17:34:49 +01:00
Aleksey Kladov
6955e392f8
remove old macro support
2019-03-17 12:53:22 +03:00
Aleksey Kladov
0d060b073c
remove hard-coded query-group macro
2019-02-11 22:24:39 +03:00
Aleksey Kladov
12e3b4c70b
reformat the world
2019-02-08 14:49:43 +03:00
Aleksey Kladov
de85f1e947
remove hard-coded support for ctry macro
...
It was used mainly to prevent HirFileId infra from bitroting, but the
`vec![]` macro can serve that just as well!
2019-02-01 10:52:36 +03:00
Aleksey Kladov
9457b1f0e6
rename source_file -> parse
2019-01-26 11:51:36 +03:00
Aleksey Kladov
4711cbcace
rename FilesDatabase -> SourceDatabase
2019-01-26 11:20:30 +03:00
Aleksey Kladov
be1a005ebd
fold syntax database into files database
2019-01-26 11:09:39 +03:00