Fix highlights; Improve example
This commit is contained in:
parent
663b436a6f
commit
616fa55d24
16
example.dust
16
example.dust
@ -1,12 +1,6 @@
|
|||||||
# Lists are created by grouping items in partheses and separating them with
|
# Comment
|
||||||
# commas.
|
(1, 2, 3);
|
||||||
|
|
||||||
numbers = (1, 2, 3);
|
random_integer();
|
||||||
|
true;
|
||||||
# To access the values in a list, use an integer as an index.
|
false;
|
||||||
|
|
||||||
x = numbers.0;
|
|
||||||
y = numbers.1;
|
|
||||||
z = numbers.2;
|
|
||||||
|
|
||||||
assert_equal(x + y, z);
|
|
@ -1,7 +1,20 @@
|
|||||||
|
(expression) @expression
|
||||||
|
(value) @value
|
||||||
(comment) @comment
|
(comment) @comment
|
||||||
(operator) @operator
|
(operator) @operator
|
||||||
(identifier) @identifier
|
(identifier) @constant
|
||||||
(value) @value
|
(value) @value
|
||||||
(string) @string
|
(string) @string
|
||||||
(tool) @function.builtin
|
|
||||||
|
(integer) @number
|
||||||
(float) @float
|
(float) @float
|
||||||
|
|
||||||
|
(yield) @keyword
|
||||||
|
(chain) @keyword
|
||||||
|
|
||||||
|
(function) @function
|
||||||
|
(tool) @function.builtin
|
||||||
|
|
||||||
|
(empty) @null
|
||||||
|
(boolean) @boolean
|
||||||
|
(list) @list
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "Dust",
|
"name": "dust",
|
||||||
"rules": {
|
"rules": {
|
||||||
"source_file": {
|
"source_file": {
|
||||||
"type": "REPEAT",
|
"type": "REPEAT",
|
||||||
|
@ -1356,7 +1356,7 @@ extern "C" {
|
|||||||
#define extern __declspec(dllexport)
|
#define extern __declspec(dllexport)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern const TSLanguage *tree_sitter_Dust(void) {
|
extern const TSLanguage *tree_sitter_dust(void) {
|
||||||
static const TSLanguage language = {
|
static const TSLanguage language = {
|
||||||
.version = LANGUAGE_VERSION,
|
.version = LANGUAGE_VERSION,
|
||||||
.symbol_count = SYMBOL_COUNT,
|
.symbol_count = SYMBOL_COUNT,
|
||||||
|
Loading…
Reference in New Issue
Block a user