Stack checker errors - Factor Documentation (original) (raw)
Stack effect checking failure conditions are reported in one of two ways:
• | Stack effect tools report them when fed quotations interactively |
---|---|
• | The Optimizing compiler reports them while compiling words, via the Batch error reporting mechanism |
Errors thrown when insufficient information is available to calculate the stack effect of a call to a combinator or macro (see Combinator stack effects): do-not-compile ( word -- * )
unknown-macro-input ( macro -- * )
bad-macro-input ( macro -- * )
Error thrown when a word's stack effect declaration does not match the composition of the stack effects of its factors:
effect-error ( inferred declared -- * )
Error thrown when branches have incompatible stack effects (see Branch stack effects):
unbalanced-branches-error ( word quots declareds actuals -- * )
Inference errors for inline recursive words (see Recursive combinator stack effects):
undeclared-recursion-error ( word -- * )
diverging-recursion-error ( word -- * )
unbalanced-recursion-error ( word height -- * )
inconsistent-recursive-call-error ( word -- * )
More obscure errors that are unlikely to arise in ordinary code:
recursive-quotation-error ( quot -- * )
too-many->r ( -- * )
too-many-r> ( -- * )
missing-effect ( word -- * )