mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-29 19:30:36 +02:00
doc: Fix typo in `set-record-type-printer!' doc.
* module/srfi/srfi-9/gnu.scm (set-record-type-printer!): Change the parameter name to `proc'. * doc/ref/api-compound.texi (SRFI-9 Records): Update accordingly.
This commit is contained in:
parent
3ae5a02f1d
commit
67768115d7
2 changed files with 5 additions and 5 deletions
|
@ -2381,9 +2381,9 @@ You may use @code{set-record-type-printer!} to customize the default printing
|
|||
behavior of records. This is a Guile extension and is not part of SRFI-9. It
|
||||
is located in the @nicode{(srfi srfi-9 gnu)} module.
|
||||
|
||||
@deffn {Scheme Syntax} set-record-type-printer! name thunk
|
||||
@deffn {Scheme Syntax} set-record-type-printer! name proc
|
||||
Where @var{type} corresponds to the first argument of @code{define-record-type},
|
||||
and @var{thunk} is a procedure accepting two arguments, the record to print, and
|
||||
and @var{proc} is a procedure accepting two arguments, the record to print, and
|
||||
an output port.
|
||||
@end deffn
|
||||
|
||||
|
|
|
@ -30,9 +30,9 @@
|
|||
set-field
|
||||
set-fields))
|
||||
|
||||
(define (set-record-type-printer! type thunk)
|
||||
"Set a custom printer THUNK for TYPE."
|
||||
(struct-set! type vtable-index-printer thunk))
|
||||
(define (set-record-type-printer! type proc)
|
||||
"Set PROC as the custom printer for TYPE."
|
||||
(struct-set! type vtable-index-printer proc))
|
||||
|
||||
(define-syntax-rule (define-immutable-record-type name ctor pred fields ...)
|
||||
((@@ (srfi srfi-9) %define-record-type)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue