Data Types & Variables
Data types:
AVIL support 4 data types that don't need a big explanation:
- int : the same of int, to represent numeric values.
- bool : for boolean values.
- string : to represent a sequence of characters (the max lenght allowed is defined by MAX_STRINGLEN here).
- label : to identify a location in the code (to allow unconditional jumps).
Variables:
All variables in an AVIL program are global and must be declared at the top of the program between the keywords var/endvar.
The variable's name must be shorter than MAX_VARNAMELEN (see Configurations).