{ $error-description "Thrown when inference encounters a macro being applied to a value which is not known to be a literal. Such code needs changes before it can compile and run. See " { $link "inference-combinators" } " and " { $link "inference-escape" } " for details." }
{ $examples
"In this example, " { $link cleave } " is being applied to an array that is constructed on the fly. This is not allowed and fails to compile with a " { $link do-not-compile } " error:"
{ $error-description "Thrown when inference encounters a combinator or macro being applied to an input parameter of a non-" { $link POSTPONE:inline } " word. The word needs to be declared " { $link POSTPONE:inline } " before its callers can compile and run. See " { $link "inference-combinators" } " and " { $link "inference-escape" } " for details." }
{ $error-description "Thrown when inference encounters a combinator or macro being applied to a value which is not known at compile time. Such code needs changes before it can compile and run. See " { $link "inference-combinators" } " and " { $link "inference-escape" } " for details." }
{ $examples
"In this example, the words being defined cannot be called, because they fail to compile with a " { $link bad-macro-input } " error:"
{ $code
": bad-example ( quot -- )"
" [ . ] append call ; inline"
""
": usage ( -- )"
" 2 2 [ + ] bad-example ;"
}
"One fix is to use " { $link compose } " instead of " { $link append } ":"
{ $error-description "Thrown when inference encounters an " { $link if } " or " { $link dispatch } " where the branches do not all exit with the same stack height. See " { $link "inference-branches" } " for details." }
{ $notes "If this error comes up when inferring the stack effect of a recursive word, check the word's stack effect declaration; it might be wrong." }
{ $error-description "Thrown when inference encounters a word lacking a stack effect declaration. Stack effects of words must be declared, with the exception of words which only push literals on the stack." }
{ $error-description "Thrown when a word's inferred stack effect does not match its declared stack effect." } ;
HELP:recursive-quotation-error
{ $error-description "Thrown when a quotation calls itself, directly or indirectly, within the same word. Stack effect inference becomes equivalent to the halting problem if quotation recursion has to be taken into account, hence it is not permitted." }
{ $error-description "Thrown when an " { $link POSTPONE:inline } " word which is not declared " { $link POSTPONE:recursive } " calls itself, directly or indirectly. The " { $link POSTPONE:recursive } " declaration is mandatory for such words." } ;
" dup call [ unbalanced-recursion-example ] [ drop ] if ;"
" inline recursive"
}
} ;
HELP:inconsistent-recursive-call-error
{ $error-description "Thrown when stack effect inference determines that an inline recursive word calls itself with a different set of quotation parameters than were input." }
"Errors thrown when insufficient information is available to calculate the stack effect of a call to a combinator or macro (see " { $link "inference-combinators" } "):"