Handbook
Glossary
struct-types&offset ( type -- pairs )
Vocabulary
cpu
.
x86
.
64
.
unix
Inputs
type
an
object
Outputs
pairs
an
object
Definition
IN:
cpu.x86.64.unix
GENERIC:
struct-types&offset
( type -- pairs )
Methods
USING:
alien.arrays
alien.c-types
arrays
cpu.x86.64.unix
math
sequences
;
M::
array
struct-types&offset
( type -- pairs )
type
unclip
:>
( dimensions element ) dimensions
array-length
<iota>
[|
i |
element
lookup-c-type
struct-types&offset
[
first2
i element
heap-size
*
+
2array
]
map
]
map
concat
;
USING:
arrays
cpu.x86.64.unix
kernel
;
M:
object
struct-types&offset
0
2array
1array
;
USING:
alien.arrays
alien.c-types
arrays
cpu.x86.64.unix
kernel
;
M:
string-type
struct-types&offset
drop
void*
base-type
0
2array
1array
;
USING:
accessors
alien.c-types
arrays
classes.struct
cpu.x86.64.unix
kernel
math
sequences
;
M:
struct-c-type
struct-types&offset
fields>>
[
[
type>>
lookup-c-type
struct-types&offset
]
[
offset>>
]
bi
'[
first2
_
+
2array
]
map
]
map
concat
;