Handbook
Glossary
splay-split ( key tree: splay -- node node )
Vocabulary
trees
.
splay
.
private
Inputs
key
an
object
tree
a
splay
Outputs
node
an
object
node
an
object
Definition
USING:
accessors
kernel
math.order
typed
;
IN:
trees.splay.private
TYPED:
splay-split
( key tree: splay -- node node )
2dup
do-splay
root>>
cmp
+lt+
=
[
nip
[
left>>
]
[
f
>>left
]
bi
]
[
nip
[
right>>
]
[
f
>>right
]
bi
swap
]
if
;