mirror of
https://github.com/status-im/realm-js.git
synced 2025-01-10 06:15:49 +00:00
24 lines
626 B
ABNF
24 lines
626 B
ABNF
|
|
|
|
pred = expr 1*WSP oper 1*WSP expr
|
|
;pred =/ "(" *WSP pred *WSP ")"
|
|
;pred =/ ("NOT" / "!") 1*WSP pred
|
|
;pred =/ pred 1*WSP ("OR" / "||") !*WSP pred
|
|
;pred =/ pred 1*WSP ("AND" / "&&") 1*WSP pred
|
|
|
|
oper = "=" / "==" / "!=" / "<" / "<=" / ">" / ">="
|
|
|
|
expr = string / num / key-path
|
|
|
|
key-path = key *("." key)
|
|
key = 1*(ALPHA / "_")
|
|
|
|
string = dq-string / sq-string
|
|
sq-string = "'" *(%x20-ffffffff) "'"
|
|
dq-string = DQUOTE *("\\" / %x20-21 / %x23-ffffffff) DQUOTE
|
|
|
|
num = ["-"] (float-num / int-num / hex-num)
|
|
float-num = (*DIGIT "." 1*DIGIT / "." 1*DIGIT)
|
|
int-num = 1*DIGIT
|
|
hex-num = ("0x" / "0X") 1*HEXDIG
|