From: Richard M. Stallman Date: Tue, 1 Nov 1994 21:04:29 +0000 (+0000) Subject: Add function and variable name conventions. X-Git-Tag: emacs-19.34~6048 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6cbf476c792cf1b493d42a71cc009ed6a0ff0dbb;p=emacs.git Add function and variable name conventions. --- diff --git a/lispref/tips.texi b/lispref/tips.texi index 1e50f672d1d..f6e240c9c41 100644 --- a/lispref/tips.texi +++ b/lispref/tips.texi @@ -73,6 +73,16 @@ Macros}. If you define a major mode, make sure to run a hook variable using @code{run-hooks}, just as the existing major modes do. @xref{Hooks}. +@item +If the purpose of a function is to tell you whether a certain condition +is true or false, give the function a name that ends in @samp{p}. If +the name is one word, add just @samp{p}; if the name is multiple words, +add @samp{-p}. Examples are @code{framep} and @code{frame-live-p}. + +@item +If a user option variable records a true-or-false condition, give it a +name that ends in @samp{-flag}. + @item Please do not define @kbd{C-c @var{letter}} as a key in your major modes. These sequences are reserved for users; they are the