Standard Gosu expressions
A Gosu expression results in a single value.
A Gosu expression is categorized by the type of operator used in constructing
it. Arithmetic expressions use arithmetic operators (+, -, *, /). Logical expressions use logical
operators (AND, OR, NOT). Other topics contain descriptions
and examples of Gosu-supported expressions and how to use them. Gosu
also supports type-cast expressions and type-checking expressions.
Expressions can also be statements. For example, the value of
obj.lookupObj() can be used as:- An argument in a method call
- A standalone statement within a statement block
Note: A statement block is also an expression, because its resulting value can be passed as
parameter to another method for subsequent execution.
