Open MangelMaxime opened 3 years ago
Hey @MangelMaxime :wave:,
Thanks for backing our project. If possible, We will handle your
issue with priority support. To make sure we don't forget how special
you are, we added a backer
label to your issue.
Thanks again for backing us :tada:!
We don't currently get any scope information from FCS for the literals or suffixes in the values, so if you wanted to fix this it would require a change to the semantic classification services upstream.
Right now these are done based off of the typecheck resolutions but it would likely need more sources of information to be able to include syntax from the syntax tree instead of just the typed tree.
I did a super-basic syntax walker + constant-value scope, and initial results are promising:
What you're seeing here is that the whole constant value, numeric and format string, is tagged with the 'SemanticClassificationType.Value' DU case, and this result is fused with the other semantic highlighting that we get from the typecheck results. The current version of FCS we use gives us a relatively limited number of SemanticClassifivationType DU cases, but FCS 40 exposes this as an enum that we can use more flexibly.
Next questions would be:
Right now this is implemented in FSAC, but this kind of AST walker, unlike the position-directed traversal that's already there, would be a prime candidate for pushing into FCS.
The upshot of this syntax-level colorization is we may not need as much/anything in the textmate grammars. Especially if we split up tokens from parsing (which is fast) and checking (which is slow)....
Hello,
when writing
let x = 43s
thes
is not of the same color as the numbers.I think it would looks better if it was having an uniform color. What do you think?
Same goes for
unit16
, etc.