Package nzdis . lang . sl ;
Helpers
tab | = | 9 |
cr | = | 13 |
lf | = | 10 |
eol | = | cr lf | cr | lf | |
white | = | ( ' ' | tab | eol ) + |
l_par | = | '(' |
r_par | = | ')' |
dot | = | '.' |
q_mark | = | '?' |
colon | = | ':' |
hash | = | '#' |
minus | = | '-' |
plus | = | '+' |
star | = | '*' |
slash | = | '/' |
semicolon | = | ';' |
pipe | = | '|' |
upper | = | [ 'A' .. 'Z' ] |
lower | = | [ 'a' .. 'z' ] |
digit | = | [ '0' .. '9' ] |
special | = | [ [ hash + colon ] + q_mark ] |
brackets | = | [ l_par + r_par ] |
integer | = | minus ? digit ( digit ) * |
float | = | minus ? digit ( digit ) * '.' digit ( digit ) * ( ( 'E' | 'e' ) ( '+' | '-' ) ? digit ( digit ) * ) ? |
not | = | 'not' |
and | = | 'and' |
or | = | 'or' |
implies | = | 'implies' |
equiv | = | 'equiv' |
true | = | 'true' |
false | = | 'false' |
sequence | = | 'sequence' |
set | = | 'set' |
forall | = | 'forall' |
exists | = | 'exists' |
feasible | = | 'feasible' |
done | = | 'done' |
action | = | 'action' |
iota | = | 'iota' |
any | = | 'any' |
all | = | 'all' |
Tokens
line_comment | = | '/' '/' [ [ 0 .. 0xffff ] - [ cr + lf ] ] * eol | ';' [ [ 0 .. 0xffff ] - [ cr + lf ] ] * eol | |
multiline_comment | = | '/' '*' [ [ 0 .. 0xffff ] - [ '*' + '/' ] ] * '*' '/' | |
string_literal | = | '"' ( [ [ 0 .. 0xffff ] - [ '"' + '\' ] ] | '\' [ 0 .. 0xffff ] ) + '"' | |
l_par | = | l_par | |
r_par | = | r_par | |
q_mark | = | q_mark | |
colon | = | colon | |
semicolon | = | semicolon | |
pipe | = | pipe | |
not | = | not | |
and | = | and | |
or | = | or | |
implies | = | implies | |
equiv | = | equiv | |
true | = | true | |
false | = | false | |
sequence | = | sequence | |
set | = | set | |
forall | = | forall | |
exists | = | exists | |
feasible | = | feasible | |
done | = | done | |
action | = | action | |
iota | = | iota | |
any | = | any | |
all | = | all | |
dot | = | dot | |
integer | = | integer | |
float | = | float | |
word | = | ( [ [ [ [ 0 .. 0xffff ] - [ 0 .. 0x20 ] ] - brackets ] - special ] ) ( [ [ [ 0 .. 0xffff ] - [ 0 .. 0x20 ] ] - brackets ] ) * | |
white | = | white |
Ignored Tokens
Productions
This site has been last updated by the web master
on 2007/6/24.