[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: documenting `elbow-hairpin`?
From: |
Jean Abou Samra |
Subject: |
Re: documenting `elbow-hairpin`? |
Date: |
Sat, 14 Aug 2021 22:42:57 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 |
Le 09/08/2021 à 17:43, Werner LEMBERG a écrit :
Function `elbow-hairpin` is defined as
(define ((elbowed-hairpin coords mirrored?) grob)
...
(export elbowed-hairpin)
Functions `flared-hairpin` and `constante-hairpin` are defined as
(define-public flared-hairpin
(elbowed-hairpin '((0 . 0) (0.95 . 0.4) (1.0 . 1.0)) #t))
(define-public constante-hairpin
(elbowed-hairpin '((0 . 0) (1.0 . 0.0) (1.0 . 1.0)) #f))
respectively. This has the consequence that the main function
`elbow-hairpin` is not documented in `notation.pdf`, and
`flared-hairpin` and `constante-hairpin` both have exactly the same
documentation (namely the documentation string from
`elbowed-hairpin`).
Can this be improved somehow?
Werner
Guile is literally translating
(define ((elbowed-hairpin coords mirrored?) grob)
...)
into
(define (elbowed-hairpin coords mirrored?)
(lambda (grob)
...))
which makes it sort of expected that if the
first element in the ellipsis is a docstring,
that ends up in the result of the application
of elbowed-hairpin rather than on elbowed-hairpin
itself.
This and the other problem with optional arguments
is pledging for a redefinition of define to make
the signature and docstring available in a more
sensible way.
Best,
Jean