tree-sitter-bynk 0.233.2 → 0.238.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
@@ -573,6 +573,10 @@ module.exports = grammar({
573
573
  seq(
574
574
  "fn",
575
575
  field("name", $.identifier),
576
+ // #926: optional `[T, …]` type parameters on the op itself — resolved
577
+ // only from an explicit type argument at the call site (mirroring
578
+ // `fn_decl`'s own `[A, B]` slot, `grammar.js:525`).
579
+ optional(seq("[", sep1(field("type_param", $.identifier), ","), "]")),
576
580
  "(",
577
581
  optional(sep1($.param, ",")),
578
582
  optional(","),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tree-sitter-bynk",
3
- "version": "0.233.2",
3
+ "version": "0.238.0",
4
4
  "description": "Tree-sitter grammar for the Bynk DSL (v0–v0.16).",
5
5
  "main": "bindings/node",
6
6
  "types": "bindings/node",
package/src/grammar.json CHANGED
@@ -2373,6 +2373,60 @@
2373
2373
  "name": "identifier"
2374
2374
  }
2375
2375
  },
2376
+ {
2377
+ "type": "CHOICE",
2378
+ "members": [
2379
+ {
2380
+ "type": "SEQ",
2381
+ "members": [
2382
+ {
2383
+ "type": "STRING",
2384
+ "value": "["
2385
+ },
2386
+ {
2387
+ "type": "SEQ",
2388
+ "members": [
2389
+ {
2390
+ "type": "FIELD",
2391
+ "name": "type_param",
2392
+ "content": {
2393
+ "type": "SYMBOL",
2394
+ "name": "identifier"
2395
+ }
2396
+ },
2397
+ {
2398
+ "type": "REPEAT",
2399
+ "content": {
2400
+ "type": "SEQ",
2401
+ "members": [
2402
+ {
2403
+ "type": "STRING",
2404
+ "value": ","
2405
+ },
2406
+ {
2407
+ "type": "FIELD",
2408
+ "name": "type_param",
2409
+ "content": {
2410
+ "type": "SYMBOL",
2411
+ "name": "identifier"
2412
+ }
2413
+ }
2414
+ ]
2415
+ }
2416
+ }
2417
+ ]
2418
+ },
2419
+ {
2420
+ "type": "STRING",
2421
+ "value": "]"
2422
+ }
2423
+ ]
2424
+ },
2425
+ {
2426
+ "type": "BLANK"
2427
+ }
2428
+ ]
2429
+ },
2376
2430
  {
2377
2431
  "type": "STRING",
2378
2432
  "value": "("
@@ -1547,6 +1547,16 @@
1547
1547
  "named": true
1548
1548
  }
1549
1549
  ]
1550
+ },
1551
+ "type_param": {
1552
+ "multiple": true,
1553
+ "required": false,
1554
+ "types": [
1555
+ {
1556
+ "type": "identifier",
1557
+ "named": true
1558
+ }
1559
+ ]
1550
1560
  }
1551
1561
  },
1552
1562
  "children": {