Either an instance of or a pointer to an FLI structure.
The name of the slot of object to be accessed.
The type of
makes accessing the object faster. If the specified type is different to the actual type,
returns the value of the object in the format of
The FLI structure type that contains slot-name . If this is passed, the compiler might be able to optimize the access to the slot. If this is omitted, the object type is determined dynamically from object .
returns the value of a slot in a specified object. An error is signaled if the slot is an aggregate type and
is not set accordingly. Use foreign-slot-pointer to access such aggregate slots.
In the following example a foreign structure is defined, an instance of the structure is made with
pointing to the instance, and
is used to set the
slot of the object to 10.
(setq my-pos (fli:allocate-foreign-object :type 'POS))
(setf (fli:foreign-slot-value my-pos 'y) 10)
(fli:foreign-slot-value my-pos 'y)
(fli:foreign-slot-value my-pos 'y :object-type 'pos)