Skip to main content

Module options

Module options 

Source
Expand description

The option keys each definer accepts — Perl Package.pm’s $*_options tables — and check_options, Perl’s CheckOptions (Package.pm:1062-1067). The runtime (Rhai) front-end checks every option bag against these; the compile-time macros check theirs at expansion.

Constants§

CONDITIONAL_OPTIONS
DefConditional (Package.pm:1185, $conditional_options).
CONSTRUCTOR_OPTIONS
DefConstructor (Package.pm:1432-1440, $constructor_options).
ENVIRONMENT_OPTIONS
DefEnvironment (Package.pm:1880-1888, $environment_options).
MACRO_OPTIONS
DefMacro (Package.pm:1136-1140, $macro_options).
MATH_OPTIONS
DefMath (Package.pm:1591-1601, $math_options).
PARAMETER_OPTIONS
DefParameterType (Package.pm:581-584, $parameter_options).
PRIMITIVE_OPTIONS
DefPrimitive (Package.pm:1277-1283, $primitive_options).
REGISTER_OPTIONS
DefRegister (Package.pm:1325-1326, $register_options).

Functions§

check_options
Perl CheckOptions($operation, $allowed, %options): one Error:misdefined naming every key allowed lacks. Returns whether all keys were allowed (Err only when the error cap escalates); the definition proceeds either way, as in Perl, with the rejected keys ignored.
unsupported_option
A key Perl accepts whose effect the core cannot carry yet: said, never silently dropped.