SRFI-99

Artifact [43cae8e149]
Login

Artifact 43cae8e149e02f7fa9b50f9aaf0fcb64c9aae359:

Wiki page [extensions] by murphy 2018-08-18 14:45:24.
D 2018-08-18T14:45:24.008
L extensions
P 761d66c48994f8e69b14bd34e0ccee3c65b40051
U murphy
W 1415
<h1>Extensions to SRFI-99</h1>

  *  The <tt>make-rtd</tt> constructor accepts four optional keyword arguments to be used after or instead of the optional parent type argument: <tt>#:parent</tt> can be used to specify the parent type, <tt>#:uid</tt> allows the explicit specification of a UID to implement non-generative records, <tt>#:sealed</tt> allows you to specify a flag preventing subtyping of the new record type if it is true and <tt>#:opaque</tt> allows you to specify a flag preventing access to the new record type descriptor through <tt>record-rtd</tt> if it is true.
  *  The procedure <tt>rtd-uid</tt> is provided to extract the UID used to tag instances of a record type.
  *  <tt>define-record-type</tt> passes additional optional arguments after the record type name through to <tt>make-rtd</tt>.
  *  Specific parts of the record type definition can be created separately using the macros <tt>define-record-constructor</tt>, <tt>define-record-predicate</tt> and <tt>define-record-field</tt>.
  *  Arbitrary [record properties] can be attached to record types using a special keyword argument <tt>#:property</tt> of <tt>make-rtd</tt>.
  *  <tt>define-record-printer</tt> is implemented in terms of record type descriptors instead of UIDs.
  *  The <tt>srfi-99-variants</tt> module, re-exported by <tt>srfi-99</tt> like <tt>srfi-99-records</tt>, allows easy definition of [variant types].

Z 50bf2c29cc1dde011c0e6ec05393eae0