compilation option pragmas

The listed pragmas here can be used to override the code generation options for a proc/method/converter.

The implementation currently provides the following possible options (various others may be added later).

pragmaallowed valuesdescription
checkson|offTurns the code generation for all runtime checks on or off.
boundCheckson|offTurns the code generation for array bound checks on or off.
overflowCheckson|offTurns the code generation for over- or underflow checks on or off.
nilCheckson|offTurns the code generation for nil pointer checks on or off.
assertionson|offTurns the code generation for assertions on or off.
warningson|offTurns the warning messages of the compiler on or off.
hintson|offTurns the hint messages of the compiler on or off.
optimizationnone|speed|sizeOptimize the code for speed or size, or disable optimization.
patternson|offTurns the term rewriting templates/macros on or off.
callconvcdecl|…Specifies the default calling convention for all procedures (and procedure types) that follow.

Example:

  1. {.checks: off, optimization: speed.}
  2. # compile without runtime checks and optimize for speed