Add list expressions

This commit is contained in:
Bruno BELANYI 2024-04-07 23:24:14 +01:00
parent f548b1d5ad
commit e13f15e8db
5 changed files with 734 additions and 193 deletions

62
src/grammar.json generated
View file

@ -82,6 +82,10 @@
{
"type": "SYMBOL",
"name": "_string_literal"
},
{
"type": "SYMBOL",
"name": "list_expression"
}
]
},
@ -211,6 +215,64 @@
}
]
}
},
"list_expression": {
"type": "SEQ",
"members": [
{
"type": "STRING",
"value": "["
},
{
"type": "CHOICE",
"members": [
{
"type": "SEQ",
"members": [
{
"type": "SYMBOL",
"name": "_expr"
},
{
"type": "REPEAT",
"content": {
"type": "SEQ",
"members": [
{
"type": "STRING",
"value": ","
},
{
"type": "SYMBOL",
"name": "_expr"
}
]
}
},
{
"type": "CHOICE",
"members": [
{
"type": "STRING",
"value": ","
},
{
"type": "BLANK"
}
]
}
]
},
{
"type": "BLANK"
}
]
},
{
"type": "STRING",
"value": "]"
}
]
}
},
"extras": [