Next: , Previous: , Up: iklib records defs   [Index]


6.19.1.10 Defining type descriptors

In a use of the syntax define-record-type, the definition clause:

(define-type-descriptors)

defines two additional syntactic bindings: one to access the record–type descriptor, the other to access the default constructor descriptor.

The syntactic identifier bound to the record–type descriptor has name equal to the record–type name with ‘-rtd’ appended. The syntactic identifier bound to the constructor descriptor has name equal to the record–type name with ‘-rcd’ appended. Example:

(define-record-type alpha
  (define-type-descriptors))

alpha-rtd       ⇒ #<record-type-descriptor>
alpha-rcd       ⇒ #<record-constructor-descriptor>