emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug Report: org-blocker-hook and org-trigger-hook are named incorrectly
@ 2009-11-27 20:28 Ryan C. Thompson
  2009-11-30 14:43 ` Carsten Dominik
  0 siblings, 1 reply; 2+ messages in thread
From: Ryan C. Thompson @ 2009-11-27 20:28 UTC (permalink / raw)
  To: org-mode Mailinglist

I believe it is the emacs convention to distinguish between hooks that 
take no arguments and hooks that do. Since org-blocker-hook and 
org-trigger-hook pass an argument to their functions, they should 
actually be called org-blocker-functions and org-trigger-functions.

 From the elisp info, 23.1 Hooks:

    If the hook variable's name does not end with `-hook', that
indicates it is probably an "abnormal hook".  That means the hook
functions are called with arguments, or their return values are used in
some way.  The hook's documentation says how the functions are called.
You can use `add-hook' to add a function to an abnormal hook, but you
must write the function to follow the hook's calling convention.
    By convention, abnormal hook names end in `-functions' or `-hooks'.
If the variable's name ends in `-function', then its value is just a
single function, not a list of functions.

-Ryan

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-11-30 14:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-11-27 20:28 Bug Report: org-blocker-hook and org-trigger-hook are named incorrectly Ryan C. Thompson
2009-11-30 14:43 ` Carsten Dominik

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.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).