Handbook
Glossary
(class-and) ( first second -- class )
Vocabulary
classes
.
algebra
.
private
Inputs
first
an
object
second
an
object
Outputs
class
an
object
Definition
USING:
classes.algebra
combinators
kernel
math.order
;
IN:
classes.algebra.private
:
(class-and)
( first second -- class )
2dup
compare-classes
{
{
+lt+
[
drop
]
}
{
+gt+
[
nip
]
}
{
+eq+
[
nip
]
}
{
+incomparable+
[
2dup
classes-intersect?
[
[
normalize-class
]
bi@
{
~array~
~array~
~array~
~array~
~quotation~
}
cond
]
[
2drop
null
]
if
]
}
}
case
;