Skip to content
This repository was archived by the owner on Apr 3, 2024. It is now read-only.

Latest commit

 

History

History
13 lines (9 loc) · 256 Bytes

grammar.md

File metadata and controls

13 lines (9 loc) · 256 Bytes
EXPR -> LITERAL | UNARY | BINARY | GROUPING

LITERAL -> number | string | "TRUE" | "FALSE"

UNARY -> ("!" | "-") EXPR

BINARY -> EXPR OP EXPR
OP -> "+" | "-" | "*" | "/" | "%" |
      "==" | "!=" | "<" | ">" | ">=" | "<="

GROUPING -> "(" EXPR ")"