Handbook
Glossary
<or-class> ( seq -- class )
Vocabulary
regexp
.
classes
Inputs
seq
an
object
Outputs
class
an
object
Definition
USING:
accessors
combinators
kernel
sequences
;
IN:
regexp.classes
:
<or-class>
( seq -- class )
dup
or-class
flatten
partition-classes
dup
not-integers>>
length
{
{
0
[
nip
make-or-class
]
}
{
1
[
not-integers>>
first
[
class>>
[
swap
class-member?
]
curry
any?
]
keep
or
]
}
[
3drop
t
]
}
case
;