GPC Developer Guides

Definitions

The sole purpose of a definition is to assign a value to a word and therefore make a script easier for a human to read. They do not use any bytecode space in a script. When a script is compiled the words are changed to their assigned value.

Syntax

define <name> = <value or expression>;
GPC


Info: The value of the definition must be possible to compute during compilation - meaning you can use math but not math functions.

Once a word is defined and given a value, that word can be used anywhere in the script where a value is valid, as shown below:

GPC


If you wish to assign a value to a word and change its value during run-time, you would use a variable instead of a define.