call ( callable -- )
Factor handbook » The language » Combinators » Fundamental combinators

Next:execute ( word -- )


Vocabulary
kernel

Inputs
callablea callable


Outputs
None

Word description
Calls a quotation or composition, or executes a word. Words which call an input parameter must be declared inline so that a caller which passes in a literal callable can have a static stack effect.

Notes
To call a non-literal quotation you can use call( to check the stack effect before calling at runtime.

Examples
The following two lines are equivalent:
2 [ 2 + 3 * ] call 2 2 + 3 *

USING: kernel math prettyprint ; 1 2 \ + call .
3


See also
call(

Definition

GENERIC: call ( callable -- )


Methods