From: "Juanma Barranquero" <lekktu@gmail.com>
To: "Kevin Rodgers" <ihs_4664@yahoo.com>
Cc: emacs-devel@gnu.org
Subject: Re: doc on define-minor-mode hook variable(s)
Date: Mon, 29 Oct 2007 11:55:00 +0100 [thread overview]
Message-ID: <f7ccd24b0710290355r35afef81m761bd7ac59fec54f@mail.gmail.com> (raw)
In-Reply-To: <dunh18$4h6$1@sea.gmane.org>
On 3/8/06, Kevin Rodgers <ihs_4664@yahoo.com> wrote:
> (defmacro defhook (symbol &rest optional-args)
> "Define SYMBOL as a hook.
[...]
> Just kidding,
Hmm. Well, kidding or not, that could be useful (yes, I know that many
people will consider it utterly unnecessary :-).
I'd love a defhook that would get a ":hook-type SOMEVALUE" keyword
argument and would do
(put my-hook 'hook SOMEVALUE)
where SOMEVALUE could be as simple `t' (normal) or `special', or
perhaps something more sophisticate indicating the expected use
(number or arguments, whether it will return something or not).
No, I don't have a use case for the "more sophisticate" case (though
it could conceivably be used by add-hook to check validity of
functions added). But certainly having all hooks marked with a
property would have uses, the first one getting rid of
`unload-feature-special-hooks'.
Just dreaming,
Juanma
next prev parent reply other threads:[~2007-10-29 10:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-05 19:40 doc on define-minor-mode hook variable(s) Drew Adams
2006-03-05 21:01 ` Stefan Monnier
2006-03-05 21:14 ` Drew Adams
2006-03-05 23:33 ` Stefan Monnier
2006-03-06 0:40 ` Drew Adams
2006-03-06 5:05 ` Stefan Monnier
2006-03-06 18:35 ` Richard Stallman
2006-03-06 19:09 ` Stefan Monnier
2006-03-08 21:06 ` Kevin Rodgers
2007-10-29 10:55 ` Juanma Barranquero [this message]
2006-03-06 19:10 ` Drew Adams
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=f7ccd24b0710290355r35afef81m761bd7ac59fec54f@mail.gmail.com \
--to=lekktu@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=ihs_4664@yahoo.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).