From: Eli Zaretskii <eliz@gnu.org>
To: Stephen Gildea <stepheng+emacs@gildea.com>
Cc: emacs-devel@gnu.org
Subject: Re: a property "definition-type" would help find macro-defined tests
Date: Fri, 10 Jan 2025 09:08:53 +0200 [thread overview]
Message-ID: <86o70f16yi.fsf@gnu.org> (raw)
In-Reply-To: <409838.1736484448@pental.sg.gildea.net> (message from Stephen Gildea on Thu, 09 Jan 2025 20:47:28 -0800)
> From: Stephen Gildea <stepheng+emacs@gildea.com>
> Date: Thu, 09 Jan 2025 20:47:28 -0800
>
> I have made the changes requested and one other:
>
> - added a NEWS entry
>
> - find-function-search-for-symbol doc string additions
> trimmed of detail that is available from the manual.
>
> - in the manual, added an index entry for the new property,
> definition-type, and for all the existing properties that
> did not have index entries (which was most of them).
>
> - in the code example, put each top-level form in @group.
>
> - new in this version of the patch: added a cross reference
> from where Coding Conventions discusses how to write macros
> that define functions.
Thanks. A few remaining nits below.
> ++++
> +** New property 'definition-type' used by find-function and friends.
"find-function" should be quoted 'like this'.
> +Macros that define an object in a way makes the object's name and the
^
I think "that" is missing there.
> @item :advertised-binding
> +@cindex @code{:advertised-binding} property
I think all these index entries should use "symbol property" instead
of the more general "property", to distinguish them from other kinds
of properties we have in Emacs.
Also, please move the index entries to _before_ the corresponding
@item's, so that following the index search will place point on the
line produced from the @item, not the line after it.
> @item customized-face
> +@cindex @code{customized-face} property
> @itemx face-defface-spec
> +@cindex @code{face-defface-spec} property
> @itemx saved-face
> +@cindex @code{saved-face} property
> @itemx theme-face
> +@cindex @code{theme-face} property
I generally find it to be more useful to have all the index entries
together before the @item..@itemx...@item lines. That way, when the
readers follow the index search, they see names of all the items
discussed in the following text, which I think is better.
> +Here is an example using a function to find the definition:
> +
> +@example
> +@group
> +(defmacro define-foo-test (data)
> + "Define a test of the foo system using DATA."
> + (declare (debug (&rest sexp)))
> + (let ((test-name (intern (concat ...))))
> + `(progn
> + (put ',test-name 'definition-type 'foo-test-type)
> + (ert-deftest ,test-name ()
> + ,(concat "Test foo with " ...)
> + ...))))
> +@end group
> +@end example
> +
> +@example
> +@group
You don't need to @end example when you @end group. Instead, have
only one @example..@end example around all the groups. The
"@group..@end group" will prevent Texinfo from inserting a page break
inside the groups, so page breaks will be only between the groups.
Thanks again for working on this.
prev parent reply other threads:[~2025-01-10 7:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-21 16:53 a property "definition-type" would help find macro-defined tests Stephen Gildea
2024-12-22 17:12 ` Richard Lawrence
2025-01-07 22:13 ` Stephen Gildea
2025-01-08 12:31 ` Eli Zaretskii
2025-01-08 17:44 ` Stephen Gildea
2025-01-09 6:57 ` Eli Zaretskii
2025-01-10 4:47 ` Stephen Gildea
2025-01-10 7:08 ` Eli Zaretskii [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86o70f16yi.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=stepheng+emacs@gildea.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).