next up previous contents
Next: 8.2.2 Alien Types and Up: 8.2 Alien Types Previous: 8.2 Alien Types

8.2.1 Defining Alien Types

Types may be either named or anonymous. With structure and union types, the name is part of the type specifier, allowing recursively defined types such as:

(struct foo (a (* (struct foo))))
An anonymous structure or union type is specified by using the name nil. The  with-alien (page gif) macro defines a local scope which ``captures'' any named type definitions. Other types are not inherently named, but can be given named abbreviations using def-alien-type.

[Macro]
alien: def-alien-type name type

This macro globally defines name as a shorthand for the Alien type type. When introducing global structure and union type definitions, name may be nil, in which case the name to define is taken from the type's name.



Raymond Toy
Mon Jul 14 09:11:27 EDT 1997