Update the docs

This commit is contained in:
Gaith Hallak 2022-06-01 14:38:16 +04:00
parent 4b81eb9646
commit 7f19cf1700

View File

@ -200,6 +200,7 @@ switch(f(x))
```c ```c
Expr ::= '(' LamArgs ')' '=>' Block(Stmt) // Anonymous function (x) => x + 1 Expr ::= '(' LamArgs ')' '=>' Block(Stmt) // Anonymous function (x) => x + 1
| '(' BinOp ')' // Operator lambda (+)
| 'if' '(' Expr ')' Expr 'else' Expr // If expression if(x < y) y else x | 'if' '(' Expr ')' Expr 'else' Expr // If expression if(x < y) y else x
| Expr ':' Type // Type annotation 5 : int | Expr ':' Type // Type annotation 5 : int
| Expr BinOp Expr // Binary operator x + y | Expr BinOp Expr // Binary operator x + y