aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2019-10-13 10:59:18 +0300
committerEli Zaretskii2019-10-13 10:59:18 +0300
commitf113ae59222dbb0961a34c1e0913cf0f3104a567 (patch)
tree1bcf37c9e38b83540e1037461f70daef60fc2d3b
parent0fcd6e320dbb7ee7614d432b7d6b5fca5b8960bc (diff)
downloademacs-f113ae59222dbb0961a34c1e0913cf0f3104a567.tar.gz
emacs-f113ae59222dbb0961a34c1e0913cf0f3104a567.zip
; Minor copyedits in a recent ELisp manual change.
* doc/lispref/tips.texi (Coding Conventions): Make the guideline against '-p' in variable names less mandatory and more constructive.
-rw-r--r--doc/lispref/tips.texi7
1 files changed, 4 insertions, 3 deletions
diff --git a/doc/lispref/tips.texi b/doc/lispref/tips.texi
index 9f6420949de..eb038164752 100644
--- a/doc/lispref/tips.texi
+++ b/doc/lispref/tips.texi
@@ -158,9 +158,10 @@ If the purpose of a function is to tell you whether a certain
158condition is true or false, give the function a name that ends in 158condition is true or false, give the function a name that ends in
159@samp{p} (which stands for ``predicate''). If the name is one word, 159@samp{p} (which stands for ``predicate''). If the name is one word,
160add just @samp{p}; if the name is multiple words, add @samp{-p}. 160add just @samp{p}; if the name is multiple words, add @samp{-p}.
161Examples are @code{framep} and @code{frame-live-p}. This predicate 161Examples are @code{framep} and @code{frame-live-p}. We recommend to
162suffix should not be used in variable names (i.e., you should name a 162avoid using this @code{-p} suffix in boolean variable names, unless
163variable @code{foo-feature} instead of @code{foo-feature-p}). 163the variable is bound to a predicate function; instead, use a
164@code{-flag} suffix or names like @code{is-foo}.
164 165
165@item 166@item
166If the purpose of a variable is to store a single function, give it a 167If the purpose of a variable is to store a single function, give it a