Next: Function Pointer Object Interfaces, Up: The Object Type [Index]
Converters from the ‘object’ type to other types are available in the form <type> __<type-name>(object), where <type> and <type-name> are replaced by the aime types and their names. Among them:
cardinal __cardinal(object); data __data(object); date __date(object); decq __decq(object); file __file(object); integer __integer(object); list __list(object); real __real(object); record __record(object); sshell __sshell(object); text __text(object); time __time(object); xshell __xshell(object);
The:
object __object(object);
function is not a converter by itself, but the implicit converters allows it to be used to box data of any type.
object __hold(integer c, object o, object r);
is o if c is not zero, r otherwise.
__hold(c, 101, "Bus 101")
evaluates to the ‘object’ boxed ‘integer’ 101 if c is not zero, to the ‘object’ boxed ‘text’ Bus 101 otherwise. As for any function, arguments are evaluated before the function call.
integer __id(object o);
is the type ID describing data boxed by o (type IDs are numerical values uniquely describing the aime types).
integer __referable(object o);
is non zero if the type of data boxed by o allows multiple data references, zero otherwise.
text __type(object o);
is the type name describing data boxed by o.
Next: Function Pointer Object Interfaces, Up: The Object Type [Index]