Lexical Conventions
Comments
Single-line comments start with
//
:// This is a single-line comment
Identifiers
Must start with a letter (
a-z
,A-Z
) or underscore (_
).Can contain letters, digits (
0-9
), and underscores.Case-sensitive.
Examples:
variableName
_myVariable
MAX_COUNT
Keywords
The following keywords are reserved and cannot be used as identifiers:
contract, function, let, if, else, while, for, return
Literals
Integer Literals: Numeric values without decimal points.
42 1000
String Literals: Text enclosed in double quotes.
"Hello, World!" "FlareScript"
Last updated