Expression

Syntax

Exp ::= STRING
      | NUMBER
      | "true"
      | "false"
      | "null"
      | "this"
      | QId "(" {NamedExp ","}* ")"
      | "!" Exp
      | QId
      | "(" Exp ")"
      | Exp "." ID "(" {NamedExp ","}* ")"
      | Exp "." ID 
      | Exp "[" Exp "]"
      | Exp Op Exp
      | Exp "?" Exp ":" Exp
      | QId "<" {Type ","}* ">" "(" {Exp ","}* ")"
      | "[" {Exp ","}* "]"
      | "(" Exp "," {Exp ","}* ")" 
      | "async" "(" {Exp ","}* ")"
      | "{" Statement* "}"
      | Exp Filter+
QId ::= ID | QId "::" ID
Op ::= "||" | "&&" | "==" | "!=" | "<"  | "<=" | ">"
     | ">=" | "*"  | "/"  | "<<" | ">>" | "&"  | "|" 
     | "%"  | "+"  | "-"  | "++" | "--"
NamedExp ::= Exp
           | ID "=" Exp
Filter ::= "where" SetExp
         | "order" "by" OrderExp
         | "prefetch" {ID ","}+
         | "limit" Exp
         | "offset" Exp
OrderExp ::= ID 
           | ID "asc"
           | ID "desc"
SetExp ::= ID "==" Exp
         | ID "!=" Exp
         | ID "<"  Exp
         | ID "<=" Exp
         | ID ">"  Exp
         | ID ">=" Exp
         | ID "in" Exp
         | ID "not" "in" Exp
         | SetExp "&&" SetExp
language/expression.txt · Last modified: 2020/03/11 10:30 by Zef Hemel