@willbooster/tree-sitter-kotlin 1.5.5 → 1.5.6

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/grammar.js CHANGED
@@ -472,7 +472,8 @@ module.exports = grammar({
472
472
  _receiver_type: ($) =>
473
473
  seq(optional($.type_modifiers), choice($.user_type, 'dynamic', $.parenthesized_type, $.nullable_type)),
474
474
 
475
- type_arguments: ($) => seq('<', commaSep1($.type_projection), '>'),
475
+ // `a<B>(c)` also reads as comparisons (`a < B > (c)`); like Kotlin's parser, prefer the type arguments.
476
+ type_arguments: ($) => prec.dynamic(1, seq('<', commaSep1($.type_projection), '>')),
476
477
 
477
478
  type_projection: ($) => choice(seq(repeat($.variance_modifier), $.type), '*'),
478
479
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@willbooster/tree-sitter-kotlin",
3
- "version": "1.5.5",
3
+ "version": "1.5.6",
4
4
  "description": "Kotlin grammar for tree-sitter",
5
5
  "keywords": [
6
6
  "incremental",
Binary file
package/tree-sitter.json CHANGED
@@ -13,7 +13,7 @@
13
13
  }
14
14
  ],
15
15
  "metadata": {
16
- "version": "1.5.5",
16
+ "version": "1.5.6",
17
17
  "license": "MIT",
18
18
  "description": "Kotlin grammar for tree-sitter",
19
19
  "authors": [