<variable-effect> ( in-var in out-var out -- effect )
Factor handbook » The language » Stack effect declarations

Prev:<terminated-effect> ( in out terminated? -- effect )


Vocabulary
effects

Inputs
in-vara string or f
ina sequence of strings or string–type pairs
out-vara string or f
outa sequence of strings or string–type pairs


Outputs
effectan effect


Word description
Constructs an effect object like <effect>. If in-var or out-var are not f, they are used as the names of the Stack effect row variables for the inputs and outputs of the effect object.

Examples
USING: effects prettyprint ; f { "a" "b" } f { "c" } <variable-effect> .
( a b -- c )

USING: effects prettyprint ; "x" { "a" "b" } "y" { "c" } <variable-effect> .
( ..x a b -- ..y c )

USING: arrays effects prettyprint ; "y" { "a" { "b" ( ..x -- ..y ) } } "x" { "c" } <variable-effect> .
( ..y a b: ( ..x -- ..y ) -- ..x c )

USING: effects prettyprint ; "." { "a" "b" } f { "*" } <variable-effect> .
( ... a b -- * )


See also
<effect>, <terminated-effect>

Definition