Handbook
Glossary
ref? ( object -- ? )
Vocabulary
refs
Inputs and outputs
object
an
object
?
a
boolean
Word description
Tests if the object is an instance of the
ref
class.
Definition
USING:
boxes
classes.tuple.private
kernel
math.private
slots.private
;
IN:
refs
:
ref?
( object -- ? )
dup
tuple?
[
layout-of
dup
7
slot
dup
\
box
eq?
[
drop
t
]
[
dup
\
slot-ref
eq?
[
drop
t
]
[
dup
\
global-var-ref
eq?
[
drop
t
]
[
dup
\
var-ref
eq?
[
drop
t
]
[
\
obj-ref
eq?
]
if
]
if
]
if
]
if
[
drop
t
]
[
dup
1
slot
9
fixnum>=
[
9
slot
dup
\
value-ref
eq?
[
drop
t
]
[
\
key-ref
eq?
]
if
]
[
drop
f
]
if
]
if
]
[
drop
f
]
if
;