Skip to content
This repository was archived by the owner on Nov 18, 2022. It is now read-only.

Commit 01c2aca

Browse files
committed
Add missing semantic token types in package.json
1 parent bf80b6c commit 01c2aca

File tree

2 files changed

+94
-1
lines changed

2 files changed

+94
-1
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
### Unreleased
22

3+
* Add missing semantic token types definition
4+
35
### 0.7.7 - 2020-05-13
46

57
* Only synchronize relevant workspace settings for RLS

package.json

Lines changed: 92 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -485,6 +485,97 @@
485485
"description": "When specified, uses the rust-analyzer binary at a given path"
486486
}
487487
}
488-
}
488+
},
489+
"semanticTokenTypes": [
490+
{
491+
"id": "attribute",
492+
"description": "Style for attributes"
493+
},
494+
{
495+
"id": "builtinType",
496+
"description": "Style for builtin types",
497+
"superType": "type"
498+
},
499+
{
500+
"id": "lifetime",
501+
"description": "Style for lifetimes"
502+
},
503+
{
504+
"id": "typeAlias",
505+
"description": "Style for type aliases",
506+
"superType": "type"
507+
},
508+
{
509+
"id": "union",
510+
"description": "Style for C-style untagged unions",
511+
"superType": "type"
512+
},
513+
{
514+
"id": "unresolvedReference",
515+
"description": "Style for names which can not be resolved due to compilation errors"
516+
},
517+
{
518+
"id": "formatSpecifier",
519+
"description": "Style for {} placeholders in format strings"
520+
}
521+
],
522+
"semanticTokenModifiers": [
523+
{
524+
"id": "constant",
525+
"description": "Style for compile-time constants"
526+
},
527+
{
528+
"id": "controlFlow",
529+
"description": "Style for control flow keywords"
530+
},
531+
{
532+
"id": "mutable",
533+
"description": "Style for mutable bindings"
534+
},
535+
{
536+
"id": "unsafe",
537+
"description": "Style for unsafe operations"
538+
}
539+
],
540+
"semanticTokenScopes": [
541+
{
542+
"language": "rust",
543+
"scopes": {
544+
"attribute": [
545+
"meta.attribute.rust"
546+
],
547+
"builtinType": [
548+
"support.type.primitive.rust"
549+
],
550+
"lifetime": [
551+
"storage.modifier.lifetime.rust"
552+
],
553+
"typeAlias": [
554+
"entity.name.type.typeAlias.rust"
555+
],
556+
"union": [
557+
"entity.name.type.union.rust"
558+
],
559+
"struct": [
560+
"entity.name.type.struct.rust"
561+
],
562+
"keyword": [
563+
"keyword.other.rust"
564+
],
565+
"keyword.controlFlow": [
566+
"keyword.control.rust"
567+
],
568+
"variable.constant": [
569+
"variable.other.constant.rust"
570+
],
571+
"formatSpecifier": [
572+
"punctuation.section.embedded.rust"
573+
],
574+
"*.mutable": [
575+
"markup.underline"
576+
]
577+
}
578+
}
579+
]
489580
}
490581
}

0 commit comments

Comments
 (0)