@willbooster/tree-sitter-python 5.1.0 → 5.2.0

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
@@ -847,8 +847,12 @@ module.exports = grammar({
847
847
  prec(
848
848
  PREC.typed_parameter,
849
849
  choice(
850
- seq(choice($.identifier, $.dictionary_splat_pattern), ':', field('type', $.type)),
851
- seq($.list_splat_pattern, ':', field('type', choice($.type, alias($._default_splat_type, $.splat_type))))
850
+ seq(field('name', choice($.identifier, $.dictionary_splat_pattern)), ':', field('type', $.type)),
851
+ seq(
852
+ field('name', $.list_splat_pattern),
853
+ ':',
854
+ field('type', choice($.type, alias($._default_splat_type, $.splat_type)))
855
+ )
852
856
  )
853
857
  ),
854
858
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@willbooster/tree-sitter-python",
3
- "version": "5.1.0",
3
+ "version": "5.2.0",
4
4
  "description": "Python grammar for tree-sitter",
5
5
  "keywords": [
6
6
  "incremental",
@@ -3361,6 +3361,24 @@
3361
3361
  "type": "typed_parameter",
3362
3362
  "named": true,
3363
3363
  "fields": {
3364
+ "name": {
3365
+ "multiple": false,
3366
+ "required": true,
3367
+ "types": [
3368
+ {
3369
+ "type": "dictionary_splat_pattern",
3370
+ "named": true
3371
+ },
3372
+ {
3373
+ "type": "identifier",
3374
+ "named": true
3375
+ },
3376
+ {
3377
+ "type": "list_splat_pattern",
3378
+ "named": true
3379
+ }
3380
+ ]
3381
+ },
3364
3382
  "type": {
3365
3383
  "multiple": false,
3366
3384
  "required": true,
@@ -3375,24 +3393,6 @@
3375
3393
  }
3376
3394
  ]
3377
3395
  }
3378
- },
3379
- "children": {
3380
- "multiple": false,
3381
- "required": true,
3382
- "types": [
3383
- {
3384
- "type": "dictionary_splat_pattern",
3385
- "named": true
3386
- },
3387
- {
3388
- "type": "identifier",
3389
- "named": true
3390
- },
3391
- {
3392
- "type": "list_splat_pattern",
3393
- "named": true
3394
- }
3395
- ]
3396
3396
  }
3397
3397
  },
3398
3398
  {
Binary file
package/tree-sitter.json CHANGED
@@ -19,7 +19,7 @@
19
19
  }
20
20
  ],
21
21
  "metadata": {
22
- "version": "5.1.0",
22
+ "version": "5.2.0",
23
23
  "license": "MIT",
24
24
  "description": "Python grammar for tree-sitter",
25
25
  "authors": [