Handbook
Glossary
struct-slot-spec
Vocabulary
classes
.
struct
Definition
USING:
slots
;
IN:
classes.struct
TUPLE:
struct-slot-spec
<
slot-spec
type packed?
;
Methods
USING:
accessors
alien
alien.c-types
classes.struct
classes.struct.private
kernel
;
M:
struct-slot-spec
(reader-quot)
[
offset>>
]
[
type>>
]
bi
[
[
[
>c-ptr
]
]
dip
]
dip
[
alien-value
]
2curry
compose
;
USING:
accessors
alien
alien.c-types
classes.struct
classes.struct.private
kernel
;
M:
struct-slot-spec
(writer-quot)
[
offset>>
]
[
type>>
]
bi
[
[
[
>c-ptr
]
]
dip
]
dip
[
set-alien-value
]
2curry
compose
;
USING:
accessors
alien.c-types
classes.struct
classes.struct.private
kernel
math
;
M:
struct-slot-spec
compute-slot-offset
[
over
c-type-align-at
8
*
align
]
keep
[
[
8
/i
]
dip
offset<<
]
[
type>>
heap-size
8
*
+
]
2bi
;