Handbook
Glossary
unrolled-2map-as ( xseq yseq len quot: ( x y -- newx ) exemplar -- newseq )
Unrolled sequence iteration combinators
Prev:
unrolled-2map ( xseq yseq len quot: ( x y -- newx ) -- newseq )
Next:
unrolled-each-integer ( n quot: ( i -- ) -- )
Vocabulary
sequences
.
unrolled
Inputs
xseq
a
sequence
yseq
a
sequence
len
an
integer
quot
a
quotation
with stack effect
( x y -- newx )
exemplar
a
sequence
Outputs
newseq
a
sequence
Word description
Unrolled version of
2map-as
that iterates over the first
len
elements of
xseq
and
yseq
.
len
must be a compile-time constant. If
seq
has fewer than
len
elements, raises an
unrolled-bounds-error
.
Definition
USING:
kernel
sequences.unrolled.private
;
IN:
sequences.unrolled
:
unrolled-2map-as
( xseq yseq len quot: ( x y -- newx ) exemplar -- newseq )
[
unrolled-2bounds-check
]
dip
unrolled-2map-as-unsafe
;
inline