Handbook
Glossary
3|| ( obj1 obj2 obj3 quots -- ? )
Factor handbook
»
The language
»
Combinators
»
Short-circuit combinators
Prev:
2|| ( obj1 obj2 quots -- ? )
Next:
n&& ( quots n -- quot )
Vocabulary
combinators
.
short-circuit
Inputs
obj1
an
object
obj2
an
object
obj3
an
object
quots
a sequence of quotations with stack effect
( obj1 obj2 obj3 -- ? )
Outputs
?
the first true result, or
f
Word description
Returns true if any quotation in the sequence returns true. Each quotation takes the same three elements from the datastack and must return a boolean.
Definition
IN:
combinators.short-circuit
:
3||
( obj1 obj2 obj3 quots -- ? )
3
n||
;