From: Peep P. <so...@us...> - 2004-03-15 19:06:54
|
Update of /cvsroot/agd/server/doc/lpc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5487 Added Files: datatypes operators Log Message: Initial import. --- NEW FILE: operators --- Operators of the LPC language. Star (*) marks that it's implemented in AGD. with side effects: = binary assign * (F_ASSIGN) -- unary decrement * (F_POSTDEC, F_PREDEC) ++ unary increment * (F_POSTINC, F_PREINC) ('a x= b' is equal to 'a = a x b') += binary self-increment -= binary self-decrement /= binary self-division *= binary self-multiplication %= binary self-modulo comparison: == binary equal * (F_EQ) > binary greater than * (F_GT) < binary less than * (F_LT) <= binary less or equal than * (F_LE) >= binary greater or equal than * (F_GE) != binary not equal * (F_NE) logic: && binary AND * || binary OR * ! unary NOT * (F_NOT) misc: -> binary call_other * (F_CALL_OTHER) note: This is different from C's ->. in LPC it calls a function in an object other than the current object; i.e. ob->call() would execute the function call() in object ob. ?: trinary conditional (if-then-else) , binary comma - left and right side are evaluated, then right side discarded. arithmetic: + binary addition * (F_ADD) - binary substraction *(F_SUB) - unary negation *(F_NEG) / binary division *(F_DIV) * binary multiplication *(F_MUL) % binary modulo * (F_MOD) ** power binary: & | ~ ^ << >> &= |= ~= ^= <<= >>= --- NEW FILE: datatypes --- Data types currently implemented in AGD are int, string, object, void. These should be fully functional everywhere. Valid, but not implemented types are mixed and type* (array type). In fact, using arrays can cause severe bugs, as they are not handled properly yet. Data types that should be working in future versions are status (memory-optimized boolean type), mapping, function, enum, struct/class and char. |