| Path: | farts.grammar |
| Last Update: | Tue Sep 13 11:33:35 GMT-5:00 2005 |
Programs are stored in the farts directory under the name <program_name.fart>
Command to manipulate triggers online is @fart:
@fart add #<oid> <progname> <eventtype> @fart del #<oid> <eventtype> @fart show #<oid>
The following event types are available:
program : stmts
stmts :
| stmts stmt
stmt : expr
| command
| if
| END
| END TRUE
| END FALSE
| '#' COMMENT
if : IF expr stmts else ENDIF
else : ELSE stmts
| command : ID
| ID STRING
expr : '!' expr
| expr '==' expr
| expr '!=' expr
| expr '>' expr
| expr '>=' expr
| expr '<' expr
| expr '<=' expr
| expr <AND|'&&'> expr
| expr <OR|'||'> expr
| '(' expr ')'
| '-' expr
| function
| atom
atom : NUMBER
| FLOAT
| STRING
| ACTOR
| ACTOR '.' ID
| THIS
| THIS '.' ID
| ARGS
| ARGS '.' ID
function : ID '(' args ')'
args :
| expr
| args ',' expr