Handbook
Glossary
set-alien-value ( c-type -- quot: ( value c-ptr offset -- ) )
Vocabulary
alien
.
c-types
Inputs
c-type
a
c-type-name
Outputs
None
Word description
Stores a value at a byte offset from a base C pointer.
Errors
Throws a
no-c-type
error if the type does not exist.
Definition
USING:
kernel
sequences
;
IN:
alien.c-types
MACRO:
set-alien-value
( c-type -- quot: ( value c-ptr offset -- ) )
[
c-type-unboxer-quot
[
[
]
]
[
[
2dip
]
curry
]
if-empty
]
[
c-type-setter
]
bi
append
;