Handbook
Glossary
slice-til-separator-inclusive ( n string tokens -- n' string slice/f ch/f )
Vocabulary
modern
.
slices
Inputs
n
an
object
string
an
object
tokens
an
object
Outputs
n'
an
object
string
an
object
slice/f
an
object
ch/f
an
object
Definition
USING:
kernel
math
sequences
sequences.extras
;
IN:
modern.slices
::
slice-til-separator-inclusive
( n string tokens -- n' string slice/f ch/f )
n string
[
tokens
member?
]
find-from
[
dup
[
1
+
]
when
]
dip
:>
( n' ch ) n' string n n' string
?<slice>
ch
;
inline