This commit is contained in:
2026-04-14 04:14:46 +02:00
parent a914892fc1
commit 6c46c1f0bb
4 changed files with 50 additions and 26 deletions
+6 -8
View File
@@ -43,21 +43,19 @@ expr_stmt = { expr ~ ";" }
// ================= EXPRESSIONS =================
type_expr = { identifier }
var_path = { identifier ~ ("." ~ identifier)* }
term = {
primary = {
integer
| float
| boolean
| string_lit
| var_path
| identifier
}
func_call = {
var_path ~ "(" ~ (expr ~ ("," ~ expr)*)? ~ ")"
postfix = {
("." ~ identifier)
| ("(" ~ (expr ~ ("," ~ expr)*)? ~ ")")
}
expr = {
func_call
| term
primary ~ postfix*
}