@willbooster/tree-sitter-c 5.0.0 → 5.0.2
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 +5 -5
- package/package.json +1 -1
- package/src/node-types.json +13 -1
- package/tree-sitter-c.wasm +0 -0
- package/tree-sitter.json +1 -1
package/grammar.js
CHANGED
|
@@ -726,6 +726,7 @@ module.exports = Object.assign(
|
|
|
726
726
|
enum_specifier: ($) =>
|
|
727
727
|
seq(
|
|
728
728
|
'enum',
|
|
729
|
+
repeat(choice($.attribute_specifier, $.attribute_declaration)),
|
|
729
730
|
choice(
|
|
730
731
|
seq(
|
|
731
732
|
field('name', $._type_identifier),
|
|
@@ -784,8 +785,7 @@ module.exports = Object.assign(
|
|
|
784
785
|
prec.right(
|
|
785
786
|
seq(
|
|
786
787
|
'struct',
|
|
787
|
-
|
|
788
|
-
optional($.ms_declspec_modifier),
|
|
788
|
+
repeat(choice($.attribute_specifier, $.attribute_declaration, $.ms_declspec_modifier)),
|
|
789
789
|
choice(
|
|
790
790
|
seq(field('name', $._type_identifier), field('body', optional($.field_declaration_list))),
|
|
791
791
|
field('body', $.field_declaration_list)
|
|
@@ -798,7 +798,7 @@ module.exports = Object.assign(
|
|
|
798
798
|
prec.right(
|
|
799
799
|
seq(
|
|
800
800
|
'union',
|
|
801
|
-
|
|
801
|
+
repeat(choice($.attribute_specifier, $.attribute_declaration, $.ms_declspec_modifier)),
|
|
802
802
|
choice(
|
|
803
803
|
seq(field('name', $._type_identifier), field('body', optional($.field_declaration_list))),
|
|
804
804
|
field('body', $.field_declaration_list)
|
|
@@ -1363,13 +1363,13 @@ module.exports = Object.assign(
|
|
|
1363
1363
|
return token(
|
|
1364
1364
|
seq(
|
|
1365
1365
|
optional(/[-+]/),
|
|
1366
|
-
optional(choice(/0[xX]/, /0[bB]/)),
|
|
1367
1366
|
choice(
|
|
1368
1367
|
seq(
|
|
1369
1368
|
choice(decimalDigits, seq(/0[bB]/, decimalDigits), seq(/0[xX]/, hexDigits)),
|
|
1370
1369
|
optional(seq('.', optional(hexDigits)))
|
|
1371
1370
|
),
|
|
1372
|
-
seq('.', decimalDigits)
|
|
1371
|
+
seq('.', decimalDigits),
|
|
1372
|
+
seq(/0[xX]/, '.', hexDigits)
|
|
1373
1373
|
),
|
|
1374
1374
|
optional(seq(/[eEpP]/, optional(seq(optional(/[-+]/), hexDigits)))),
|
|
1375
1375
|
/[uUlLwWfFbBdD]*/
|
package/package.json
CHANGED
package/src/node-types.json
CHANGED
|
@@ -1520,9 +1520,13 @@
|
|
|
1520
1520
|
}
|
|
1521
1521
|
},
|
|
1522
1522
|
"children": {
|
|
1523
|
-
"multiple":
|
|
1523
|
+
"multiple": true,
|
|
1524
1524
|
"required": false,
|
|
1525
1525
|
"types": [
|
|
1526
|
+
{
|
|
1527
|
+
"type": "attribute_declaration",
|
|
1528
|
+
"named": true
|
|
1529
|
+
},
|
|
1526
1530
|
{
|
|
1527
1531
|
"type": "attribute_specifier",
|
|
1528
1532
|
"named": true
|
|
@@ -3746,6 +3750,10 @@
|
|
|
3746
3750
|
"multiple": true,
|
|
3747
3751
|
"required": false,
|
|
3748
3752
|
"types": [
|
|
3753
|
+
{
|
|
3754
|
+
"type": "attribute_declaration",
|
|
3755
|
+
"named": true
|
|
3756
|
+
},
|
|
3749
3757
|
{
|
|
3750
3758
|
"type": "attribute_specifier",
|
|
3751
3759
|
"named": true
|
|
@@ -4195,6 +4203,10 @@
|
|
|
4195
4203
|
"multiple": true,
|
|
4196
4204
|
"required": false,
|
|
4197
4205
|
"types": [
|
|
4206
|
+
{
|
|
4207
|
+
"type": "attribute_declaration",
|
|
4208
|
+
"named": true
|
|
4209
|
+
},
|
|
4198
4210
|
{
|
|
4199
4211
|
"type": "attribute_specifier",
|
|
4200
4212
|
"named": true
|
package/tree-sitter-c.wasm
CHANGED
|
Binary file
|