Next: , Previous: Operators, Up: Marsyas Expression Syntax Variables

Variable names must start with a letter but may be followed by letters or numbers. hello and hi8 are valid names wheras 2much is not. The type of a variable is defined through assignment. 12 >> x defines variable x of type natural. Once a variable type is defined it cannot be changed, 12 >> x, 'hello' >> x results in a type mismatch error. There is no notion of scope except that all variables are in the same scope so that variables defined within a conditional statement will exist outside the conditional and after it has been evaluated.

Control Names ( /absolute/path or relative/path )

Control names are written using the path notation, /Gain/gain/mrs_real/gain.

Aliases ( @name )

Control names can be rather long. Aliases can be used to shorten expressions containing control names. Making an alias is done through assignment to a name preceded by the symbol: /Gain/gain/mrs_real/gain >> @gain. After assignment, the alias can be used as any other variable name: gain << 0.5.