From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Juanma Barranquero <lekktu@gmail.com>
Cc: Emacs developers <emacs-devel@gnu.org>
Subject: Re: master 49192e9: Strip "(fn...)" from output of `describe-mode' (bug#38222)
Date: Tue, 19 Nov 2019 14:22:53 -0500 [thread overview]
Message-ID: <jwvd0dn7k5b.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <CAAeL0STHw3MTz2zenRfXkJcz=sX_j_5YYaPhVTHGaR-pBr_7Kg@mail.gmail.com> (Juanma Barranquero's message of "Tue, 19 Nov 2019 19:47:15 +0100")
> help-split-fundoc returns nil if the docstring has no usage string.
>
> (help-split-fundoc (documentation 'auto-composition-mode)
> 'auto-composition-mode) => nil
IIRC you can use
(let* ((doc (documentation NAME))
(fd (help-split-fundoc doc NAME)))
(if fd (cdr fd) doc))
But I agree that `help-split-fundoc` is inconvenient.
Improvements welcome. Maybe it should always return a pair (USAGE
. DOC) so we could just do:
(cdr (help-split-fundoc (documentation NAME) NAME)
-- Stefan
next prev parent reply other threads:[~2019-11-19 19:22 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20191119101930.28082.63466@vcs0.savannah.gnu.org>
[not found] ` <20191119101931.EA4E2209BF@vcs0.savannah.gnu.org>
2019-11-19 13:54 ` master 49192e9: Strip "(fn...)" from output of `describe-mode' (bug#38222) Stefan Monnier
2019-11-19 18:47 ` Juanma Barranquero
2019-11-19 19:22 ` Stefan Monnier [this message]
2019-11-19 19:45 ` Juanma Barranquero
2019-11-19 20:05 ` Stefan Monnier
2019-11-19 20:25 ` Juanma Barranquero
2019-11-19 20:56 ` Stefan Monnier
2019-11-19 21:26 ` Drew Adams
2019-11-22 20:00 ` Juanma Barranquero
2019-11-22 21:45 ` Stefan Monnier
2019-11-23 21:12 ` Juanma Barranquero
2019-11-23 22:08 ` Stefan Monnier
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwvd0dn7k5b.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.org \
--cc=lekktu@gmail.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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.