Next: iklib memory condition, Previous: iklib memory ops, Up: iklib memory [Index]
The following bindings are exported by the libraries (vicare)
and (vicare system $foreign)
and reexported by the library
(vicare ffi)
.
<memory-block>
Disjoint object used to reference a raw memory block through a pointer and number of bytes. It has the following public fields:
pointer
A pointer object referencing the first byte of memory.
size
The number of bytes in the memory block; it is an exact integer in the
range of the C language type size_t
.
Build and return a new instance of memory-block
referencing a
memory block pointed to by pointer and of size number of
bytes.
When a memory-block
built by make-memory-block
is garbage
collected: nothing happens.
When a memory-block
built by make-memory-block/guarded
is
garbage collected: the referenced memory block is released with
free
from (vicare)
.
Return #t
if obj is an instance of memory-block
.
Return #t
if obj is an instance of memory-block
and
the pointer is not NULL
.
Accessors for the fields of memory-block
instances. The pointer
object returned by memory-block-pointer
is a copy of the pointer
object in mblock.
Reset an instance of memory-block
to a NULL
pointer and zero
size; return unspecified values. If mblock has been created to
release the referenced memory block: the memory block is freed.
Build and return a new instance of memory-block
holding a new
NULL
pointer object and zero as size.
All the arguments must be instances of <memory-block>
. Return #t
if all the arguments
have equal memory address and block size; otherwise return #f
. When applied to a single
argument: return #t
.
The arguments must be <memory-block>
instances. Return #t
if the arguments are all
different: no two arguments are equal; otherwise return #f
. When applied to a single
argument: return #f
.
Next: iklib memory condition, Previous: iklib memory ops, Up: iklib memory [Index]