Handbook
Glossary
(deep-find) ( ... obj quot: ( ... elt -- ... ? ) -- ... elt ? )
Vocabulary
sequences
.
deep
Inputs
obj
an
object
quot
a
quotation
with stack effect
( ... elt -- ... ? )
Outputs
elt
an
object
?
an
object
Definition
USING:
kernel
sequences
;
IN:
sequences.deep
:
(deep-find)
( ... obj quot: ( ... elt -- ... ? ) -- ... elt ? )
[
call
]
2check
[
drop
t
]
[
over
branch?
[
[
f
]
2dip
[
[
nip
]
]
dip
[
(deep-find)
]
curry
compose
any?
]
[
2drop
f
f
]
if
]
if
;
inline
recursive