Skip to content

Commit

Permalink
Added Various Different Schemas remaining
Browse files Browse the repository at this point in the history
Signed-off-by: Vishal <[email protected]>
  • Loading branch information
Vishalk91-4 committed Jul 29, 2024
1 parent ec2fd3e commit 5621fed
Show file tree
Hide file tree
Showing 5 changed files with 71,002 additions and 69,804 deletions.
5 changes: 5 additions & 0 deletions grammar.js
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,11 @@ module.exports = grammar({
schema_statement: $ => prec.left(seq(
'schema',
field('name', $.parameter),
optional(seq(
'(',
field('base', $.identifier),
')'
)),
':',
field('body', $._suite),
)),
Expand Down
29 changes: 29 additions & 0 deletions src/grammar.json
Original file line number Diff line number Diff line change
Expand Up @@ -962,6 +962,35 @@
"name": "parameter"
}
},
{
"type": "CHOICE",
"members": [
{
"type": "SEQ",
"members": [
{
"type": "STRING",
"value": "("
},
{
"type": "FIELD",
"name": "base",
"content": {
"type": "SYMBOL",
"name": "identifier"
}
},
{
"type": "STRING",
"value": ")"
}
]
},
{
"type": "BLANK"
}
]
},
{
"type": "STRING",
"value": ":"
Expand Down
10 changes: 10 additions & 0 deletions src/node-types.json
Original file line number Diff line number Diff line change
Expand Up @@ -2074,6 +2074,16 @@
"type": "schema_statement",
"named": true,
"fields": {
"base": {
"multiple": false,
"required": false,
"types": [
{
"type": "identifier",
"named": true
}
]
},
"body": {
"multiple": false,
"required": true,
Expand Down
Loading

0 comments on commit 5621fed

Please sign in to comment.