tm-grammars 1.32.16 → 1.32.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -38,7 +38,7 @@ import { grammars } from 'tm-grammars'
38
38
  | `awk` | | [luggage66/vscode-awk](https://github.com/luggage66/vscode-awk/blob/eff8c0f160ae16592c8d9963fd77046137fd2612/syntaxes/awk.tmLanguage) | [MIT](https://raw.githubusercontent.com/luggage66/vscode-awk/master/LICENSE.txt) | | | 5.16 kB |
39
39
  | `ballerina` | | [ballerina-platform/ballerina-grammar](https://github.com/ballerina-platform/ballerina-grammar/blob/4bf70d328ae9e5a93219e44c031ab3776c76727a/syntaxes/ballerina.tmLanguage) | [Apache-2.0](https://raw.githubusercontent.com/ballerina-platform/ballerina-grammar/master/LICENSE) | | | 55.03 kB |
40
40
  | `bat` | `batch` `cmd` | [microsoft/vscode](https://github.com/microsoft/vscode/blob/df15c8e832a341633acd2e9bb26e1b275d09cfe0/extensions/bat/syntaxes/batchfile.tmLanguage.json) | [MIT](https://raw.githubusercontent.com/microsoft/vscode/main/LICENSE.txt) | | | 12.29 kB |
41
- | `beancount` | | [Lencerf/vscode-beancount](https://github.com/Lencerf/vscode-beancount/blob/75fc29960fcf6666e4b06310fac4d49a16c57ca0/syntaxes/beancount.tmLanguage) | [MIT](https://raw.githubusercontent.com/Lencerf/vscode-beancount/master/LICENSE) | | | 9.90 kB |
41
+ | `beancount` | | [Lencerf/vscode-beancount](https://github.com/Lencerf/vscode-beancount/blob/60dcdbd3af273aca0ff628220f2828483101ca47/syntaxes/beancount.tmLanguage) | [MIT](https://raw.githubusercontent.com/Lencerf/vscode-beancount/master/LICENSE) | | | 12.26 kB |
42
42
  | `berry` | `be` | [berry-lang/berry](https://github.com/berry-lang/berry/blob/74611286b8d2d2c2ee16ea187029f2a9c4257f5f/tools/plugins/vscode/skiars.berry-1.2.0/syntaxes/berry.json) | [MIT](https://raw.githubusercontent.com/berry-lang/berry/master/LICENSE) | | | 2.63 kB |
43
43
  | `bibtex` | | [microsoft/vscode](https://github.com/microsoft/vscode/blob/9a2c94d213696a4453b6d9988b003d98e7646e75/extensions/latex/syntaxes/Bibtex.tmLanguage.json) | [MIT](https://raw.githubusercontent.com/microsoft/vscode/main/LICENSE.txt) | | | 4.51 kB |
44
44
  | `bicep` | | [Azure/bicep](https://github.com/Azure/bicep/blob/6252abb94141fc6e774a53652404be30f1cb9000/src/textmate/bicep.tmlanguage) | [MIT](https://raw.githubusercontent.com/Azure/bicep/main/LICENSE) | | | 4.92 kB |
@@ -239,7 +239,7 @@ import { grammars } from 'tm-grammars'
239
239
  | `turtle` | | [stardog-union/stardog-vsc](https://github.com/stardog-union/stardog-vsc/blob/3f1364b08bdbf4b4d77f123682db7d2b708b2f6e/stardog-rdf-grammars/syntaxes/turtle.tmLanguage.json) | | | | 3.49 kB |
240
240
  | `twig` | | [mblode/vscode-twig-language-2](https://github.com/mblode/vscode-twig-language-2/blob/73f4e2729ce5f490e294dd158c82c22a35cf96de/src/syntaxes/twig.tmLanguage) | [MIT](https://raw.githubusercontent.com/mblode/vscode-twig-language-2/master/LICENSE.md) | [GitHub Sponsors: **@mblode**](https://github.com/sponsors/mblode) | `javascript` `css` `scss` `php` `python` `ruby` | 23.40 kB |
241
241
  | `typescript` | `ts` `cts` `mts` | [microsoft/vscode](https://github.com/microsoft/vscode/blob/210541906e5a96ab39f9c753f921b1bd35f4138b/extensions/typescript-basics/syntaxes/TypeScript.tmLanguage.json) | [MIT](https://raw.githubusercontent.com/microsoft/vscode/main/LICENSE.txt) | | | 160.03 kB |
242
- | `typespec` | `tsp` | [microsoft/typespec](https://github.com/microsoft/typespec/blob/64f7850fb6e6069965ba8774643241b6a74f881c/grammars/typespec.json) | [MIT](https://raw.githubusercontent.com/microsoft/typespec/main/LICENSE) | | | 23.94 kB |
242
+ | `typespec` | `tsp` | [microsoft/typespec](https://github.com/microsoft/typespec/blob/8e16f8cfffd431f2a04647f8f98bbc98e8f6fcd0/grammars/typespec.json) | [MIT](https://raw.githubusercontent.com/microsoft/typespec/main/LICENSE) | | | 25.34 kB |
243
243
  | `typst` | `typ` | [Myriad-Dreamin/tinymist](https://github.com/Myriad-Dreamin/tinymist/blob/32f908199ee17ea295512bbc27166e890c438175/editors/vscode/package.json) | [Apache-2.0](https://raw.githubusercontent.com/Myriad-Dreamin/tinymist/main/LICENSE) | | `bat` `bibtex` `c` `clojure` `coffee` `cpp` `css` `csharp` `dart` `diff` `docker` `elixir` `erlang` `fsharp` `git-commit` `git-rebase` `go` `groovy` `handlebars` `html` `ini` `java` `javascript` `jsonc` `json` `julia` `latex` `less` `log` `lua` `make` `markdown` `objective-c` `perl` `raku` `php` `powershell` `pug` `r` `regexp` `ruby` `scss` `sql` `swift` `xml` `xsl` `yaml` `python` `rust` `scala` `shellscript` `typescript` `tsx` `twig` `verilog` `system-verilog` `vb` | 151.64 kB |
244
244
  | `v` | | [vlang/vscode-vlang](https://github.com/vlang/vscode-vlang/blob/cc6dee79af1fc1332084a263b952489aaed7e884/syntaxes/v.tmLanguage.json) | [MIT](https://raw.githubusercontent.com/vlang/vscode-vlang/master/LICENSE) | | | 12.56 kB |
245
245
  | `vala` | | [vala-lang/vala-vscode](https://github.com/vala-lang/vala-vscode/blob/8f825e95648326df2572d0522632251cdff4a43b/syntaxes/vala.YAML-tmLanguage) | [MIT](https://raw.githubusercontent.com/vala-lang/vala-vscode/master/LICENSE) | | | 3.12 kB |
@@ -325,6 +325,106 @@
325
325
  }
326
326
  ]
327
327
  },
328
+ {
329
+ "begin": "([0-9]{4})([-/|])([0-9]{2})([-/|])([0-9]{2})\\s+(query)\\s+(\"(?:[^\"\\\\]|\\\\.)*\")\\s+(\")",
330
+ "beginCaptures": {
331
+ "1": {
332
+ "name": "constant.numeric.date.year.beancount"
333
+ },
334
+ "2": {
335
+ "name": "punctuation.separator.beancount"
336
+ },
337
+ "3": {
338
+ "name": "constant.numeric.date.month.beancount"
339
+ },
340
+ "4": {
341
+ "name": "punctuation.separator.beancount"
342
+ },
343
+ "5": {
344
+ "name": "constant.numeric.date.day.beancount"
345
+ },
346
+ "6": {
347
+ "name": "support.function.directive.beancount"
348
+ },
349
+ "7": {
350
+ "name": "string.quoted.double.beancount"
351
+ },
352
+ "8": {
353
+ "name": "punctuation.definition.string.begin.beancount"
354
+ }
355
+ },
356
+ "end": "(\")",
357
+ "endCaptures": {
358
+ "1": {
359
+ "name": "punctuation.definition.string.end.beancount"
360
+ }
361
+ },
362
+ "name": "meta.directive.query.beancount",
363
+ "patterns": [
364
+ {
365
+ "include": "#comments"
366
+ },
367
+ {
368
+ "begin": "/\\*",
369
+ "end": "\\*/",
370
+ "name": "comment.block.bql"
371
+ },
372
+ {
373
+ "match": "\\b[0-9]{4}-[0-9]{2}-[0-9]{2}\\b",
374
+ "name": "constant.numeric.date.bql"
375
+ },
376
+ {
377
+ "match": "\\b(?i:SELECT|FROM|WHERE|GROUP|ORDER|HAVING|LIMIT|PIVOT|AND|OR|NOT|IN|IS|BETWEEN|AS|DISTINCT|ASC|DESC|TRUE|FALSE|NULL|CREATE|TABLE|USING|INSERT|INTO|BALANCES|JOURNAL|PRINT|BY)\\b",
378
+ "name": "keyword.control.bql"
379
+ },
380
+ {
381
+ "match": "\\b(?i:abs|bool|int|decimal|str|date|year|month|day|yearmonth|quarter|weekday|today|root|parent|leaf|grepn??|subst|upper|lower|maxwidth|substr|splitcomp|length|repr|round|safediv|neg|open_date|close_date|open_meta|meta|entry_meta|any_meta|currency_meta|commodity_meta|account_sortkey|has_account|units|cost|value|getprice|number|currency|commodity|findfirst|joinstr|only|empty|filter_currency|convert|parse_date|date_diff|date_add|date_trunc|date_part|interval|date_bin|getitem|possign|sum|count|first|last|min|max)\\b(?=\\s*\\()",
382
+ "name": "support.function.bql"
383
+ },
384
+ {
385
+ "match": "\\b(?i:id|type|filename|lineno|location|date|year|month|day|flag|payee|narration|description|tags|links|meta|accounts?|other_accounts|posting_flag|number|currency|cost_number|cost_currency|cost_date|cost_label|position|price|weight|balance|entry)\\b",
386
+ "name": "variable.other.column.bql"
387
+ },
388
+ {
389
+ "begin": "\"",
390
+ "end": "\"",
391
+ "name": "string.quoted.double.bql",
392
+ "patterns": [
393
+ {
394
+ "match": "\"\"",
395
+ "name": "constant.character.escape.bql"
396
+ }
397
+ ]
398
+ },
399
+ {
400
+ "begin": "'",
401
+ "end": "'",
402
+ "name": "string.quoted.single.bql",
403
+ "patterns": [
404
+ {
405
+ "match": "''",
406
+ "name": "constant.character.escape.bql"
407
+ }
408
+ ]
409
+ },
410
+ {
411
+ "match": "\\b\\d+(\\.\\d+)?\\b",
412
+ "name": "constant.numeric.bql"
413
+ },
414
+ {
415
+ "match": "<=|>=|!=|[<=>]|\\?~|!~|~",
416
+ "name": "keyword.operator.comparison.bql"
417
+ },
418
+ {
419
+ "match": "[-%*+/]",
420
+ "name": "keyword.operator.arithmetic.bql"
421
+ },
422
+ {
423
+ "match": "[(),]",
424
+ "name": "punctuation.bql"
425
+ }
426
+ ]
427
+ },
328
428
  {
329
429
  "begin": "([0-9]{4})([-/|])([0-9]{2})([-/|])([0-9]{2})\\s(price)",
330
430
  "beginCaptures": {
@@ -17,7 +17,7 @@
17
17
  "name": "keyword.operator.assignment.tsp"
18
18
  }
19
19
  },
20
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
20
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
21
21
  "name": "meta.alias-id.typespec",
22
22
  "patterns": [
23
23
  {
@@ -38,7 +38,7 @@
38
38
  "name": "entity.name.type.tsp"
39
39
  }
40
40
  },
41
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
41
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
42
42
  "name": "meta.alias-statement.typespec",
43
43
  "patterns": [
44
44
  {
@@ -59,7 +59,7 @@
59
59
  "name": "entity.name.tag.tsp"
60
60
  }
61
61
  },
62
- "end": "(?=([$_`[:alpha:]]))|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
62
+ "end": "(?=([$_`[:alpha:]]))|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
63
63
  "name": "meta.augment-decorator-statement.typespec",
64
64
  "patterns": [
65
65
  {
@@ -121,7 +121,7 @@
121
121
  "name": "variable.name.tsp"
122
122
  }
123
123
  },
124
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
124
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
125
125
  "name": "meta.const-statement.typespec",
126
126
  "patterns": [
127
127
  {
@@ -145,7 +145,7 @@
145
145
  "name": "entity.name.tag.tsp"
146
146
  }
147
147
  },
148
- "end": "(?=([$_`[:alpha:]]))|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
148
+ "end": "(?=([$_`[:alpha:]]))|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
149
149
  "name": "meta.decorator.typespec",
150
150
  "patterns": [
151
151
  {
@@ -172,7 +172,7 @@
172
172
  "name": "entity.name.function.tsp"
173
173
  }
174
174
  },
175
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
175
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
176
176
  "name": "meta.decorator-declaration-statement.typespec",
177
177
  "patterns": [
178
178
  {
@@ -193,7 +193,7 @@
193
193
  "name": "keyword.directive.name.tsp"
194
194
  }
195
195
  },
196
- "end": "$|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
196
+ "end": "$|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
197
197
  "name": "meta.directive.typespec",
198
198
  "patterns": [
199
199
  {
@@ -308,6 +308,27 @@
308
308
  }
309
309
  ]
310
310
  },
311
+ "enum-expression": {
312
+ "begin": "\\b(enum)\\b(?:\\s+(\\b[$_[:alpha:]][$_[:alnum:]]*\\b|`(?:[^\\\\`]|\\\\.)*`))?",
313
+ "beginCaptures": {
314
+ "1": {
315
+ "name": "keyword.other.tsp"
316
+ },
317
+ "2": {
318
+ "name": "entity.name.type.tsp"
319
+ }
320
+ },
321
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
322
+ "name": "meta.enum-expression.typespec",
323
+ "patterns": [
324
+ {
325
+ "include": "#token"
326
+ },
327
+ {
328
+ "include": "#enum-body"
329
+ }
330
+ ]
331
+ },
311
332
  "enum-member": {
312
333
  "begin": "(\\b[$_[:alpha:]][$_[:alnum:]]*\\b|`(?:[^\\\\`]|\\\\.)*`)\\s*(:?)",
313
334
  "beginCaptures": {
@@ -318,7 +339,7 @@
318
339
  "name": "keyword.operator.type.annotation.tsp"
319
340
  }
320
341
  },
321
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
342
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
322
343
  "name": "meta.enum-member.typespec",
323
344
  "patterns": [
324
345
  {
@@ -342,7 +363,7 @@
342
363
  "name": "entity.name.type.tsp"
343
364
  }
344
365
  },
345
- "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
366
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
346
367
  "name": "meta.enum-statement.typespec",
347
368
  "patterns": [
348
369
  {
@@ -386,6 +407,18 @@
386
407
  {
387
408
  "include": "#tuple-expression"
388
409
  },
410
+ {
411
+ "include": "#model-expression-keyword"
412
+ },
413
+ {
414
+ "include": "#scalar-expression"
415
+ },
416
+ {
417
+ "include": "#enum-expression"
418
+ },
419
+ {
420
+ "include": "#union-expression"
421
+ },
389
422
  {
390
423
  "include": "#model-expression"
391
424
  },
@@ -413,7 +446,7 @@
413
446
  "name": "entity.name.function.tsp"
414
447
  }
415
448
  },
416
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
449
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
417
450
  "name": "meta.function-declaration-statement.typespec",
418
451
  "patterns": [
419
452
  {
@@ -438,7 +471,7 @@
438
471
  "name": "keyword.other.tsp"
439
472
  }
440
473
  },
441
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
474
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
442
475
  "name": "meta.import-statement.typespec",
443
476
  "patterns": [
444
477
  {
@@ -485,7 +518,7 @@
485
518
  "name": "keyword.other.tsp"
486
519
  }
487
520
  },
488
- "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b))",
521
+ "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b))",
489
522
  "name": "meta.interface-heritage.typespec",
490
523
  "patterns": [
491
524
  {
@@ -506,7 +539,7 @@
506
539
  "name": "entity.name.function.tsp"
507
540
  }
508
541
  },
509
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
542
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
510
543
  "name": "meta.interface-member.typespec",
511
544
  "patterns": [
512
545
  {
@@ -527,7 +560,7 @@
527
560
  "name": "keyword.other.tsp"
528
561
  }
529
562
  },
530
- "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
563
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
531
564
  "name": "meta.interface-statement.typespec",
532
565
  "patterns": [
533
566
  {
@@ -586,6 +619,33 @@
586
619
  }
587
620
  ]
588
621
  },
622
+ "model-expression-keyword": {
623
+ "begin": "\\b(model)\\b(?:\\s+(?!(?:extend|i)s\\b)(\\b[$_[:alpha:]][$_[:alnum:]]*\\b|`(?:[^\\\\`]|\\\\.)*`))?",
624
+ "beginCaptures": {
625
+ "1": {
626
+ "name": "keyword.other.tsp"
627
+ },
628
+ "2": {
629
+ "name": "entity.name.type.tsp"
630
+ }
631
+ },
632
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
633
+ "name": "meta.model-expression-keyword.typespec",
634
+ "patterns": [
635
+ {
636
+ "include": "#token"
637
+ },
638
+ {
639
+ "include": "#type-parameters"
640
+ },
641
+ {
642
+ "include": "#model-heritage"
643
+ },
644
+ {
645
+ "include": "#expression"
646
+ }
647
+ ]
648
+ },
589
649
  "model-heritage": {
590
650
  "begin": "\\b(extends|is)\\b",
591
651
  "beginCaptures": {
@@ -593,7 +653,7 @@
593
653
  "name": "keyword.other.tsp"
594
654
  }
595
655
  },
596
- "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b))",
656
+ "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b))",
597
657
  "name": "meta.model-heritage.typespec",
598
658
  "patterns": [
599
659
  {
@@ -614,7 +674,7 @@
614
674
  "name": "string.quoted.double.tsp"
615
675
  }
616
676
  },
617
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
677
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
618
678
  "name": "meta.model-property.typespec",
619
679
  "patterns": [
620
680
  {
@@ -641,7 +701,7 @@
641
701
  "name": "keyword.other.tsp"
642
702
  }
643
703
  },
644
- "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
704
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
645
705
  "name": "meta.model-statement.typespec",
646
706
  "patterns": [
647
707
  {
@@ -680,7 +740,7 @@
680
740
  },
681
741
  "namespace-name": {
682
742
  "begin": "(?=([$_`[:alpha:]]))",
683
- "end": "((?=\\{)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b))",
743
+ "end": "((?=\\{)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b))",
684
744
  "name": "meta.namespace-name.typespec",
685
745
  "patterns": [
686
746
  {
@@ -698,7 +758,7 @@
698
758
  "name": "keyword.other.tsp"
699
759
  }
700
760
  },
701
- "end": "((?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b))",
761
+ "end": "((?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b))",
702
762
  "name": "meta.namespace-statement.typespec",
703
763
  "patterns": [
704
764
  {
@@ -758,7 +818,7 @@
758
818
  "name": "keyword.operator.type.annotation.tsp"
759
819
  }
760
820
  },
761
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
821
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
762
822
  "name": "meta.object-literal-property.typespec",
763
823
  "patterns": [
764
824
  {
@@ -776,7 +836,7 @@
776
836
  "name": "keyword.other.tsp"
777
837
  }
778
838
  },
779
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
839
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
780
840
  "name": "meta.operation-heritage.typespec",
781
841
  "patterns": [
782
842
  {
@@ -845,7 +905,7 @@
845
905
  "name": "entity.name.function.tsp"
846
906
  }
847
907
  },
848
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
908
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
849
909
  "name": "meta.operation-statement.typespec",
850
910
  "patterns": [
851
911
  {
@@ -934,7 +994,7 @@
934
994
  "name": "entity.name.function.tsp"
935
995
  }
936
996
  },
937
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
997
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
938
998
  "name": "meta.scalar-constructor.typespec",
939
999
  "patterns": [
940
1000
  {
@@ -945,6 +1005,33 @@
945
1005
  }
946
1006
  ]
947
1007
  },
1008
+ "scalar-expression": {
1009
+ "begin": "\\b(scalar)\\b(?:\\s+(?!extends\\b)(\\b[$_[:alpha:]][$_[:alnum:]]*\\b|`(?:[^\\\\`]|\\\\.)*`))?",
1010
+ "beginCaptures": {
1011
+ "1": {
1012
+ "name": "keyword.other.tsp"
1013
+ },
1014
+ "2": {
1015
+ "name": "entity.name.type.tsp"
1016
+ }
1017
+ },
1018
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1019
+ "name": "meta.scalar-expression.typespec",
1020
+ "patterns": [
1021
+ {
1022
+ "include": "#token"
1023
+ },
1024
+ {
1025
+ "include": "#type-parameters"
1026
+ },
1027
+ {
1028
+ "include": "#scalar-extends"
1029
+ },
1030
+ {
1031
+ "include": "#scalar-body"
1032
+ }
1033
+ ]
1034
+ },
948
1035
  "scalar-extends": {
949
1036
  "begin": "\\b(extends)\\b",
950
1037
  "beginCaptures": {
@@ -952,7 +1039,7 @@
952
1039
  "name": "keyword.other.tsp"
953
1040
  }
954
1041
  },
955
- "end": "(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1042
+ "end": "(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
956
1043
  "name": "meta.scalar-extends.typespec",
957
1044
  "patterns": [
958
1045
  {
@@ -976,7 +1063,7 @@
976
1063
  "name": "entity.name.type.tsp"
977
1064
  }
978
1065
  },
979
- "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1066
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
980
1067
  "name": "meta.scalar-statement.typespec",
981
1068
  "patterns": [
982
1069
  {
@@ -1000,7 +1087,7 @@
1000
1087
  "name": "keyword.operator.spread.tsp"
1001
1088
  }
1002
1089
  },
1003
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1090
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1004
1091
  "name": "meta.spread-operator.typespec",
1005
1092
  "patterns": [
1006
1093
  {
@@ -1190,7 +1277,7 @@
1190
1277
  "name": "keyword.operator.type.annotation.tsp"
1191
1278
  }
1192
1279
  },
1193
- "end": "(?=[),;=@}]|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1280
+ "end": "(?=[),;=@}]|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1194
1281
  "name": "meta.type-annotation.typespec",
1195
1282
  "patterns": [
1196
1283
  {
@@ -1208,7 +1295,7 @@
1208
1295
  "name": "keyword.operator.assignment.tsp"
1209
1296
  }
1210
1297
  },
1211
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1298
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1212
1299
  "endCaptures": {
1213
1300
  "0": {
1214
1301
  "name": "keyword.operator.assignment.tsp"
@@ -1260,7 +1347,7 @@
1260
1347
  "name": "entity.name.type.tsp"
1261
1348
  }
1262
1349
  },
1263
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1350
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1264
1351
  "name": "meta.type-parameter.typespec",
1265
1352
  "patterns": [
1266
1353
  {
@@ -1281,7 +1368,7 @@
1281
1368
  "name": "keyword.other.tsp"
1282
1369
  }
1283
1370
  },
1284
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1371
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1285
1372
  "name": "meta.type-parameter-constraint.typespec",
1286
1373
  "patterns": [
1287
1374
  {
@@ -1296,7 +1383,7 @@
1296
1383
  "name": "keyword.operator.assignment.tsp"
1297
1384
  }
1298
1385
  },
1299
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1386
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1300
1387
  "name": "meta.type-parameter-default.typespec",
1301
1388
  "patterns": [
1302
1389
  {
@@ -1334,7 +1421,7 @@
1334
1421
  "name": "keyword.other.tsp"
1335
1422
  }
1336
1423
  },
1337
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1424
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1338
1425
  "name": "meta.typeof.typespec",
1339
1426
  "patterns": [
1340
1427
  {
@@ -1377,6 +1464,33 @@
1377
1464
  }
1378
1465
  ]
1379
1466
  },
1467
+ "union-expression": {
1468
+ "begin": "\\b(union)\\b(?:\\s+(?!extends\\b)(\\b[$_[:alpha:]][$_[:alnum:]]*\\b|`(?:[^\\\\`]|\\\\.)*`))?",
1469
+ "beginCaptures": {
1470
+ "1": {
1471
+ "name": "keyword.other.tsp"
1472
+ },
1473
+ "2": {
1474
+ "name": "entity.name.type.tsp"
1475
+ }
1476
+ },
1477
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1478
+ "name": "meta.union-expression.typespec",
1479
+ "patterns": [
1480
+ {
1481
+ "include": "#token"
1482
+ },
1483
+ {
1484
+ "include": "#type-parameters"
1485
+ },
1486
+ {
1487
+ "include": "#union-extends"
1488
+ },
1489
+ {
1490
+ "include": "#union-body"
1491
+ }
1492
+ ]
1493
+ },
1380
1494
  "union-extends": {
1381
1495
  "begin": "\\b(extends)\\b",
1382
1496
  "beginCaptures": {
@@ -1384,7 +1498,7 @@
1384
1498
  "name": "keyword.other.tsp"
1385
1499
  }
1386
1500
  },
1387
- "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b))",
1501
+ "end": "((?=\\{)|(?=[);@}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b))",
1388
1502
  "name": "meta.union-extends.typespec",
1389
1503
  "patterns": [
1390
1504
  {
@@ -1408,7 +1522,7 @@
1408
1522
  "name": "entity.name.type.tsp"
1409
1523
  }
1410
1524
  },
1411
- "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1525
+ "end": "(?<=})|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1412
1526
  "name": "meta.union-statement.typespec",
1413
1527
  "patterns": [
1414
1528
  {
@@ -1435,7 +1549,7 @@
1435
1549
  "name": "keyword.operator.type.annotation.tsp"
1436
1550
  }
1437
1551
  },
1438
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1552
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1439
1553
  "name": "meta.union-variant.typespec",
1440
1554
  "patterns": [
1441
1555
  {
@@ -1453,7 +1567,7 @@
1453
1567
  "name": "keyword.other.tsp"
1454
1568
  }
1455
1569
  },
1456
- "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1570
+ "end": "(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1457
1571
  "name": "meta.using-statement.typespec",
1458
1572
  "patterns": [
1459
1573
  {
@@ -1474,7 +1588,7 @@
1474
1588
  "name": "keyword.other.tsp"
1475
1589
  }
1476
1590
  },
1477
- "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|model|op|using|import|enum|alias|union|interface|dec|fn)\\b)",
1591
+ "end": "(?=>)|(?=[,;@]|#[a-z]|[)}]|\\b(?:extern|internal)\\b|\\b(?:namespace|op|using|import|alias|interface|dec|fn)\\b)",
1478
1592
  "name": "meta.valueof.typespec",
1479
1593
  "patterns": [
1480
1594
  {
package/index.js CHANGED
@@ -442,19 +442,19 @@ export const grammars = [
442
442
  sourceApi: 'https://api.github.com/repos/microsoft/vscode/contents/extensions/bat/syntaxes/batchfile.tmLanguage.json?ref=df15c8e832a341633acd2e9bb26e1b275d09cfe0',
443
443
  },
444
444
  {
445
- byteSize: 10133,
445
+ byteSize: 12556,
446
446
  displayName: 'Beancount',
447
447
  funding: [
448
448
  ],
449
- hash: 'jpKPT3sRW7Nshq0bSM7Y-mmstCJUMvWOblCqHRnleTY',
450
- lastUpdate: '2024-10-02T08:25:15Z',
449
+ hash: 'Oae9U_FYogMNm9-KQP5sf1p65hQFP85gkIHL4XH_Wgg',
450
+ lastUpdate: '2026-09-07T21:38:06Z',
451
451
  license: 'MIT',
452
452
  licenseUrl: 'https://raw.githubusercontent.com/Lencerf/vscode-beancount/master/LICENSE',
453
453
  name: 'beancount',
454
454
  scopeName: 'text.beancount',
455
- sha: '75fc29960fcf6666e4b06310fac4d49a16c57ca0',
456
- source: 'https://github.com/Lencerf/vscode-beancount/blob/75fc29960fcf6666e4b06310fac4d49a16c57ca0/syntaxes/beancount.tmLanguage',
457
- sourceApi: 'https://api.github.com/repos/Lencerf/vscode-beancount/contents/syntaxes/beancount.tmLanguage?ref=75fc29960fcf6666e4b06310fac4d49a16c57ca0',
455
+ sha: '60dcdbd3af273aca0ff628220f2828483101ca47',
456
+ source: 'https://github.com/Lencerf/vscode-beancount/blob/60dcdbd3af273aca0ff628220f2828483101ca47/syntaxes/beancount.tmLanguage',
457
+ sourceApi: 'https://api.github.com/repos/Lencerf/vscode-beancount/contents/syntaxes/beancount.tmLanguage?ref=60dcdbd3af273aca0ff628220f2828483101ca47',
458
458
  },
459
459
  {
460
460
  aliases: [
@@ -4652,19 +4652,19 @@ export const grammars = [
4652
4652
  aliases: [
4653
4653
  'tsp',
4654
4654
  ],
4655
- byteSize: 24513,
4655
+ byteSize: 25946,
4656
4656
  displayName: 'TypeSpec',
4657
4657
  funding: [
4658
4658
  ],
4659
- hash: '9Z5ySOhdzZ6qem4q8p-OqjrTN2-biM6nuW25ko0uCs0',
4660
- lastUpdate: '2026-09-03T18:19:21Z',
4659
+ hash: 'hIGg98XQ5qfnkhYtXnAr7qb2Ro8pMLU3bEa5zDvUSdU',
4660
+ lastUpdate: '2026-09-11T12:41:06Z',
4661
4661
  license: 'MIT',
4662
4662
  licenseUrl: 'https://raw.githubusercontent.com/microsoft/typespec/main/LICENSE',
4663
4663
  name: 'typespec',
4664
4664
  scopeName: 'source.tsp',
4665
- sha: '64f7850fb6e6069965ba8774643241b6a74f881c',
4666
- source: 'https://github.com/microsoft/typespec/blob/64f7850fb6e6069965ba8774643241b6a74f881c/grammars/typespec.json',
4667
- sourceApi: 'https://api.github.com/repos/microsoft/typespec/contents/grammars/typespec.json?ref=64f7850fb6e6069965ba8774643241b6a74f881c',
4665
+ sha: '8e16f8cfffd431f2a04647f8f98bbc98e8f6fcd0',
4666
+ source: 'https://github.com/microsoft/typespec/blob/8e16f8cfffd431f2a04647f8f98bbc98e8f6fcd0/grammars/typespec.json',
4667
+ sourceApi: 'https://api.github.com/repos/microsoft/typespec/contents/grammars/typespec.json?ref=8e16f8cfffd431f2a04647f8f98bbc98e8f6fcd0',
4668
4668
  },
4669
4669
  {
4670
4670
  aliases: [
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "tm-grammars",
3
3
  "type": "module",
4
- "version": "1.32.16",
4
+ "version": "1.32.18",
5
5
  "description": "Collecton of TextMate grammars in JSON",
6
6
  "author": "Anthony Fu <anthonyfu117@hotmail.com>",
7
7
  "license": "MIT",