Email or username:

Password:

Forgot your password?
Andrew Tropin

@graywolf Answering your question in Guile's IRC about record introspection: to obtain fields of a record-type there is record-type-fields function.

You can go even further and get a list of fields from record itself.
(record-type-fields (record-type-descriptor (%make-some-record 1 2 3)))

r6rs records introspection have a bit more consistent naming:
(use-modules (rnrs records inspection))
(record-type-fields (record-rtd (%make-record 1 2 3)))

#scheme #guile #lisp

1 comment
graywolf

@abcdw Oh that is great. Thank you for going out of your way to tell me! :) Now I can finally adjust my documentation generator to produce @deftp instead of @defvar. Yeeey.

Go Up