aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorGlenn Morris2012-05-04 20:37:30 -0400
committerGlenn Morris2012-05-04 20:37:30 -0400
commitddff335186c805b3756cff110033fe118f548f17 (patch)
tree91b95a190047e233c13feec4cb82fbe34d2c4c14 /doc
parent9824f5052394817ac65302d42a7c97841593e19e (diff)
downloademacs-ddff335186c805b3756cff110033fe118f548f17.tar.gz
emacs-ddff335186c805b3756cff110033fe118f548f17.zip
More small edits for doc/lispref
* control.texi: Where possible, use example rather than smallexample. (Sequencing, Conditionals, Signaling Errors, Handling Errors): Tweak page breaks. * customize.texi: Where possible, use example rather than smallexample. (Common Keywords, Variable Definitions, Applying Customizations) (Custom Themes): Tweak page breaks. * eval.texi, functions.texi, loading.texi, macros.texi: Where possible, use example rather than smallexample. * sequences.texi (Arrays): Tweak page breaks. * symbols.texi: Where possible, use example rather than smallexample. (Symbol Components): Fix typo. (Other Plists): Tweak page break.
Diffstat (limited to 'doc')
-rw-r--r--doc/lispref/ChangeLog19
-rw-r--r--doc/lispref/control.texi60
-rw-r--r--doc/lispref/customize.texi62
-rw-r--r--doc/lispref/eval.texi25
-rw-r--r--doc/lispref/functions.texi28
-rw-r--r--doc/lispref/loading.texi52
-rw-r--r--doc/lispref/macros.texi38
-rw-r--r--doc/lispref/sequences.texi2
-rw-r--r--doc/lispref/symbols.texi22
9 files changed, 161 insertions, 147 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index 2cb961cab55..beaf0c0476b 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -1,3 +1,22 @@
12012-05-05 Glenn Morris <rgm@gnu.org>
2
3 * eval.texi, functions.texi, loading.texi, macros.texi:
4 Where possible, use example rather than smallexample.
5
6 * symbols.texi: Where possible, use example rather than smallexample.
7 (Symbol Components): Fix typo.
8 (Other Plists): Tweak page break.
9
10 * sequences.texi (Arrays): Tweak page breaks.
11
12 * customize.texi: Where possible, use example rather than smallexample.
13 (Common Keywords, Variable Definitions, Applying Customizations)
14 (Custom Themes): Tweak page breaks.
15
16 * control.texi: Where possible, use example rather than smallexample.
17 (Sequencing, Conditionals, Signaling Errors, Handling Errors):
18 Tweak page breaks.
19
12012-05-04 Glenn Morris <rgm@gnu.org> 202012-05-04 Glenn Morris <rgm@gnu.org>
2 21
3 * lists.texi (List-related Predicates, List Variables): 22 * lists.texi (List-related Predicates, List Variables):
diff --git a/doc/lispref/control.texi b/doc/lispref/control.texi
index f8f9ddfa2e8..95b70e87c93 100644
--- a/doc/lispref/control.texi
+++ b/doc/lispref/control.texi
@@ -1,6 +1,6 @@
1@c -*-texinfo-*- 1@c -*-texinfo-*-
2@c This is part of the GNU Emacs Lisp Reference Manual. 2@c This is part of the GNU Emacs Lisp Reference Manual.
3@c Copyright (C) 1990-1995, 1998-1999, 2001-2012 Free Software Foundation, Inc. 3@c Copyright (C) 1990-1995, 1998-1999, 2001-2012 Free Software Foundation, Inc.
4@c See the file elisp.texi for copying conditions. 4@c See the file elisp.texi for copying conditions.
5@setfilename ../../info/control 5@setfilename ../../info/control
6@node Control Structures, Variables, Evaluation, Top 6@node Control Structures, Variables, Evaluation, Top
@@ -94,8 +94,8 @@ order, returning the result of the final form.
94@end example 94@end example
95@end defspec 95@end defspec
96 96
97 Two other control constructs likewise evaluate a series of forms but return 97 Two other constructs likewise evaluate a series of forms but return
98a different value: 98different values:
99 99
100@defspec prog1 form1 forms@dots{} 100@defspec prog1 form1 forms@dots{}
101This special form evaluates @var{form1} and all of the @var{forms}, in 101This special form evaluates @var{form1} and all of the @var{forms}, in
@@ -160,8 +160,8 @@ If @var{condition} has the value @code{nil}, and no @var{else-forms} are
160given, @code{if} returns @code{nil}. 160given, @code{if} returns @code{nil}.
161 161
162@code{if} is a special form because the branch that is not selected is 162@code{if} is a special form because the branch that is not selected is
163never evaluated---it is ignored. Thus, in the example below, 163never evaluated---it is ignored. Thus, in this example,
164@code{true} is not printed because @code{print} is never called. 164@code{true} is not printed because @code{print} is never called:
165 165
166@example 166@example
167@group 167@group
@@ -258,9 +258,7 @@ clauses was successful. To do this, we use @code{t} as the
258@var{condition} of the last clause, like this: @code{(t 258@var{condition} of the last clause, like this: @code{(t
259@var{body-forms})}. The form @code{t} evaluates to @code{t}, which is 259@var{body-forms})}. The form @code{t} evaluates to @code{t}, which is
260never @code{nil}, so this clause never fails, provided the @code{cond} 260never @code{nil}, so this clause never fails, provided the @code{cond}
261gets to it at all. 261gets to it at all. For example:
262
263For example,
264 262
265@example 263@example
266@group 264@group
@@ -812,10 +810,10 @@ handlers that handle the error: @code{condition-case} binds a local
812variable to a list of the form @code{(@var{error-symbol} .@: 810variable to a list of the form @code{(@var{error-symbol} .@:
813@var{data})} (@pxref{Handling Errors}). 811@var{data})} (@pxref{Handling Errors}).
814 812
815The function @code{signal} never returns (though in older Emacs versions 813The function @code{signal} never returns.
816it could sometimes return). 814@c (though in older Emacs versions it sometimes could).
817 815
818@smallexample 816@example
819@group 817@group
820(signal 'wrong-number-of-arguments '(x y)) 818(signal 'wrong-number-of-arguments '(x y))
821 @error{} Wrong number of arguments: x, y 819 @error{} Wrong number of arguments: x, y
@@ -825,7 +823,7 @@ it could sometimes return).
825(signal 'no-such-error '("My unknown error condition")) 823(signal 'no-such-error '("My unknown error condition"))
826 @error{} peculiar error: "My unknown error condition" 824 @error{} peculiar error: "My unknown error condition"
827@end group 825@end group
828@end smallexample 826@end example
829@end defun 827@end defun
830 828
831@cindex CL note---no continuable errors 829@cindex CL note---no continuable errors
@@ -991,7 +989,7 @@ to allow the debugger to run before the handler); @var{body} is one or more
991Lisp expressions to be executed when this handler handles an error. 989Lisp expressions to be executed when this handler handles an error.
992Here are examples of handlers: 990Here are examples of handlers:
993 991
994@smallexample 992@example
995@group 993@group
996(error nil) 994(error nil)
997 995
@@ -1001,7 +999,7 @@ Here are examples of handlers:
1001 (message 999 (message
1002 "Either division by zero or failure to open a file")) 1000 "Either division by zero or failure to open a file"))
1003@end group 1001@end group
1004@end smallexample 1002@end example
1005 1003
1006Each error that occurs has an @dfn{error symbol} that describes what 1004Each error that occurs has an @dfn{error symbol} that describes what
1007kind of error it is. The @code{error-conditions} property of this 1005kind of error it is. The @code{error-conditions} property of this
@@ -1034,9 +1032,9 @@ Sometimes it is necessary to re-throw a signal caught by
1034@code{condition-case}, for some outer-level handler to catch. Here's 1032@code{condition-case}, for some outer-level handler to catch. Here's
1035how to do that: 1033how to do that:
1036 1034
1037@smallexample 1035@example
1038 (signal (car err) (cdr err)) 1036 (signal (car err) (cdr err))
1039@end smallexample 1037@end example
1040 1038
1041@noindent 1039@noindent
1042where @code{err} is the error description variable, the first argument 1040where @code{err} is the error description variable, the first argument
@@ -1055,7 +1053,7 @@ Here is an example of using @code{condition-case} to handle the error
1055that results from dividing by zero. The handler displays the error 1053that results from dividing by zero. The handler displays the error
1056message (but without a beep), then returns a very large number. 1054message (but without a beep), then returns a very large number.
1057 1055
1058@smallexample 1056@example
1059@group 1057@group
1060(defun safe-divide (dividend divisor) 1058(defun safe-divide (dividend divisor)
1061 (condition-case err 1059 (condition-case err
@@ -1076,22 +1074,24 @@ message (but without a beep), then returns a very large number.
1076 @print{} Arithmetic error: (arith-error) 1074 @print{} Arithmetic error: (arith-error)
1077@result{} 1000000 1075@result{} 1000000
1078@end group 1076@end group
1079@end smallexample 1077@end example
1080 1078
1081@noindent 1079@noindent
1082The handler specifies condition name @code{arith-error} so that it will handle only division-by-zero errors. Other kinds of errors will not be handled, at least not by this @code{condition-case}. Thus, 1080The handler specifies condition name @code{arith-error} so that it
1081will handle only division-by-zero errors. Other kinds of errors will
1082not be handled (by this @code{condition-case}). Thus:
1083 1083
1084@smallexample 1084@example
1085@group 1085@group
1086(safe-divide nil 3) 1086(safe-divide nil 3)
1087 @error{} Wrong type argument: number-or-marker-p, nil 1087 @error{} Wrong type argument: number-or-marker-p, nil
1088@end group 1088@end group
1089@end smallexample 1089@end example
1090 1090
1091 Here is a @code{condition-case} that catches all kinds of errors, 1091 Here is a @code{condition-case} that catches all kinds of errors,
1092including those signaled with @code{error}: 1092including those from @code{error}:
1093 1093
1094@smallexample 1094@example
1095@group 1095@group
1096(setq baz 34) 1096(setq baz 34)
1097 @result{} 34 1097 @result{} 34
@@ -1109,7 +1109,7 @@ including those signaled with @code{error}:
1109@print{} The error was: (error "Rats! The variable baz was 34, not 35") 1109@print{} The error was: (error "Rats! The variable baz was 34, not 35")
1110@result{} 2 1110@result{} 2
1111@end group 1111@end group
1112@end smallexample 1112@end example
1113 1113
1114@defmac ignore-errors body@dots{} 1114@defmac ignore-errors body@dots{}
1115This construct executes @var{body}, ignoring any errors that occur 1115This construct executes @var{body}, ignoring any errors that occur
@@ -1120,12 +1120,12 @@ otherwise, it returns @code{nil}.
1120Here's the example at the beginning of this subsection rewritten using 1120Here's the example at the beginning of this subsection rewritten using
1121@code{ignore-errors}: 1121@code{ignore-errors}:
1122 1122
1123@smallexample 1123@example
1124@group 1124@group
1125 (ignore-errors 1125 (ignore-errors
1126 (delete-file filename)) 1126 (delete-file filename))
1127@end group 1127@end group
1128@end smallexample 1128@end example
1129@end defmac 1129@end defmac
1130 1130
1131@defmac with-demoted-errors body@dots{} 1131@defmac with-demoted-errors body@dots{}
@@ -1280,7 +1280,7 @@ Variables}).
1280 For example, here we make an invisible buffer for temporary use, and 1280 For example, here we make an invisible buffer for temporary use, and
1281make sure to kill it before finishing: 1281make sure to kill it before finishing:
1282 1282
1283@smallexample 1283@example
1284@group 1284@group
1285(let ((buffer (get-buffer-create " *temp*"))) 1285(let ((buffer (get-buffer-create " *temp*")))
1286 (with-current-buffer buffer 1286 (with-current-buffer buffer
@@ -1288,7 +1288,7 @@ make sure to kill it before finishing:
1288 @var{body-form} 1288 @var{body-form}
1289 (kill-buffer buffer)))) 1289 (kill-buffer buffer))))
1290@end group 1290@end group
1291@end smallexample 1291@end example
1292 1292
1293@noindent 1293@noindent
1294You might think that we could just as well write @code{(kill-buffer 1294You might think that we could just as well write @code{(kill-buffer
@@ -1313,7 +1313,7 @@ is protected with a form that guarantees deletion of the process in the
1313event of failure. Otherwise, Emacs might fill up with useless 1313event of failure. Otherwise, Emacs might fill up with useless
1314subprocesses. 1314subprocesses.
1315 1315
1316@smallexample 1316@example
1317@group 1317@group
1318(let ((win nil)) 1318(let ((win nil))
1319 (unwind-protect 1319 (unwind-protect
@@ -1324,7 +1324,7 @@ subprocesses.
1324 (error "Ftp login failed"))) 1324 (error "Ftp login failed")))
1325 (or win (and process (delete-process process))))) 1325 (or win (and process (delete-process process)))))
1326@end group 1326@end group
1327@end smallexample 1327@end example
1328 1328
1329 This example has a small bug: if the user types @kbd{C-g} to 1329 This example has a small bug: if the user types @kbd{C-g} to
1330quit, and the quit happens immediately after the function 1330quit, and the quit happens immediately after the function
diff --git a/doc/lispref/customize.texi b/doc/lispref/customize.texi
index 92bd7a80ac6..be224987d29 100644
--- a/doc/lispref/customize.texi
+++ b/doc/lispref/customize.texi
@@ -1,6 +1,6 @@
1@c -*-texinfo-*- 1@c -*-texinfo-*-
2@c This is part of the GNU Emacs Lisp Reference Manual. 2@c This is part of the GNU Emacs Lisp Reference Manual.
3@c Copyright (C) 1997-2012 Free Software Foundation, Inc. 3@c Copyright (C) 1997-2012 Free Software Foundation, Inc.
4@c See the file elisp.texi for copying conditions. 4@c See the file elisp.texi for copying conditions.
5@setfilename ../../info/customize 5@setfilename ../../info/customize
6@node Customization, Loading, Macros, Top 6@node Customization, Loading, Macros, Top
@@ -158,7 +158,7 @@ Packages distributed as part of Emacs that use the
158@defvar customize-package-emacs-version-alist 158@defvar customize-package-emacs-version-alist
159This alist provides a mapping for the versions of Emacs that are 159This alist provides a mapping for the versions of Emacs that are
160associated with versions of a package listed in the 160associated with versions of a package listed in the
161@code{:package-version} keyword. Its elements look like this: 161@code{:package-version} keyword. Its elements are:
162 162
163@example 163@example
164(@var{package} (@var{pversion} . @var{eversion})@dots{}) 164(@var{package} (@var{pversion} . @var{eversion})@dots{})
@@ -169,6 +169,8 @@ elements that contain a package version @var{pversion} with an
169associated Emacs version @var{eversion}. These versions are strings. 169associated Emacs version @var{eversion}. These versions are strings.
170For example, the MH-E package updates this alist with the following: 170For example, the MH-E package updates this alist with the following:
171 171
172@c Must be small else too wide.
173@c FIXME obviously this is out of date (in the code).
172@smallexample 174@smallexample
173(add-to-list 'customize-package-emacs-version-alist 175(add-to-list 'customize-package-emacs-version-alist
174 '(MH-E ("6.0" . "22.1") ("6.1" . "22.1") ("7.0" . "22.1") 176 '(MH-E ("6.0" . "22.1") ("6.1" . "22.1") ("7.0" . "22.1")
@@ -395,7 +397,7 @@ Set the variable's @code{safe-local-variable} property to
395@item :set-after @var{variables} 397@item :set-after @var{variables}
396@kindex set-after@r{, @code{defcustom} keyword} 398@kindex set-after@r{, @code{defcustom} keyword}
397When setting variables according to saved customizations, make sure to 399When setting variables according to saved customizations, make sure to
398set the variables @var{variables} before this one; in other words, delay 400set the variables @var{variables} before this one; i.e., delay
399setting this variable until after those others have been handled. Use 401setting this variable until after those others have been handled. Use
400@code{:set-after} if setting this variable won't work properly unless 402@code{:set-after} if setting this variable won't work properly unless
401those other variables already have their intended values. 403those other variables already have their intended values.
@@ -682,9 +684,9 @@ The argument to the @code{:options} keywords should be a list of
682specifications for reasonable keys in the alist. Ordinarily, they are 684specifications for reasonable keys in the alist. Ordinarily, they are
683simply atoms, which stand for themselves. For example: 685simply atoms, which stand for themselves. For example:
684 686
685@smallexample 687@example
686:options '("foo" "bar" "baz") 688:options '("foo" "bar" "baz")
687@end smallexample 689@end example
688 690
689@noindent 691@noindent
690specifies that there are three ``known'' keys, namely @code{"foo"}, 692specifies that there are three ``known'' keys, namely @code{"foo"},
@@ -696,9 +698,9 @@ integer. You can specify this by using a list instead of an atom in
696the list. The first element will specify the key, like before, while 698the list. The first element will specify the key, like before, while
697the second element will specify the value type. For example: 699the second element will specify the value type. For example:
698 700
699@smallexample 701@example
700:options '("foo" ("bar" integer) "baz") 702:options '("foo" ("bar" integer) "baz")
701@end smallexample 703@end example
702 704
703Finally, you may want to change how the key is presented. By default, 705Finally, you may want to change how the key is presented. By default,
704the key is simply shown as a @code{const}, since the user cannot change 706the key is simply shown as a @code{const}, since the user cannot change
@@ -708,37 +710,37 @@ you may want to use a more specialized type for presenting the key, like
708This is done by using a customization type specification instead of a 710This is done by using a customization type specification instead of a
709symbol for the key. 711symbol for the key.
710 712
711@smallexample 713@example
712:options '("foo" ((function-item some-function) integer) 714:options '("foo" ((function-item some-function) integer)
713 "baz") 715 "baz")
714@end smallexample 716@end example
715 717
716Many alists use lists with two elements, instead of cons cells. For 718Many alists use lists with two elements, instead of cons cells. For
717example, 719example,
718 720
719@smallexample 721@example
720(defcustom list-alist '(("foo" 1) ("bar" 2) ("baz" 3)) 722(defcustom list-alist '(("foo" 1) ("bar" 2) ("baz" 3))
721 "Each element is a list of the form (KEY VALUE).") 723 "Each element is a list of the form (KEY VALUE).")
722@end smallexample 724@end example
723 725
724@noindent 726@noindent
725instead of 727instead of
726 728
727@smallexample 729@example
728(defcustom cons-alist '(("foo" . 1) ("bar" . 2) ("baz" . 3)) 730(defcustom cons-alist '(("foo" . 1) ("bar" . 2) ("baz" . 3))
729 "Each element is a cons-cell (KEY . VALUE).") 731 "Each element is a cons-cell (KEY . VALUE).")
730@end smallexample 732@end example
731 733
732Because of the way lists are implemented on top of cons cells, you can 734Because of the way lists are implemented on top of cons cells, you can
733treat @code{list-alist} in the example above as a cons cell alist, where 735treat @code{list-alist} in the example above as a cons cell alist, where
734the value type is a list with a single element containing the real 736the value type is a list with a single element containing the real
735value. 737value.
736 738
737@smallexample 739@example
738(defcustom list-alist '(("foo" 1) ("bar" 2) ("baz" 3)) 740(defcustom list-alist '(("foo" 1) ("bar" 2) ("baz" 3))
739 "Each element is a list of the form (KEY VALUE)." 741 "Each element is a list of the form (KEY VALUE)."
740 :type '(alist :value-type (group integer))) 742 :type '(alist :value-type (group integer)))
741@end smallexample 743@end example
742 744
743The @code{group} widget is used here instead of @code{list} only because 745The @code{group} widget is used here instead of @code{list} only because
744the formatting is better suited for the purpose. 746the formatting is better suited for the purpose.
@@ -746,14 +748,14 @@ the formatting is better suited for the purpose.
746Similarly, you can have alists with more values associated with each 748Similarly, you can have alists with more values associated with each
747key, using variations of this trick: 749key, using variations of this trick:
748 750
749@smallexample 751@example
750(defcustom person-data '(("brian" 50 t) 752(defcustom person-data '(("brian" 50 t)
751 ("dorith" 55 nil) 753 ("dorith" 55 nil)
752 ("ken" 52 t)) 754 ("ken" 52 t))
753 "Alist of basic info about people. 755 "Alist of basic info about people.
754Each element has the form (NAME AGE MALE-FLAG)." 756Each element has the form (NAME AGE MALE-FLAG)."
755 :type '(alist :value-type (group integer boolean))) 757 :type '(alist :value-type (group integer boolean)))
756@end smallexample 758@end example
757 759
758@item (plist :key-type @var{key-type} :value-type @var{value-type}) 760@item (plist :key-type @var{key-type} :value-type @var{value-type})
759This customization type is similar to @code{alist} (see above), except 761This customization type is similar to @code{alist} (see above), except
@@ -1264,7 +1266,7 @@ customization settings for variables and faces, respectively. When
1264the user invokes @samp{Save for future sessions} in the Customize 1266the user invokes @samp{Save for future sessions} in the Customize
1265interface, that takes effect by writing a @code{custom-set-variables} 1267interface, that takes effect by writing a @code{custom-set-variables}
1266and/or a @code{custom-set-faces} form into the custom file, to be 1268and/or a @code{custom-set-faces} form into the custom file, to be
1267evaluated the next time Emacs starts up. 1269evaluated the next time Emacs starts.
1268 1270
1269@defun custom-set-variables &rest args 1271@defun custom-set-variables &rest args
1270This function installs the variable customizations specified by 1272This function installs the variable customizations specified by
@@ -1335,11 +1337,10 @@ the theme; this is the description shown when the user invokes the
1335@code{describe-theme} command or types @kbd{?} in the @samp{*Custom 1337@code{describe-theme} command or types @kbd{?} in the @samp{*Custom
1336Themes*} buffer. 1338Themes*} buffer.
1337 1339
1338Two special theme names are disallowed: @code{user} is a ``dummy'' 1340Two special theme names are disallowed (using them causes an error):
1339theme which stores the user's direct customization settings, and 1341@code{user} is a ``dummy'' theme that stores the user's direct
1340@code{changed} is a ``dummy'' theme which stores changes made outside 1342customization settings, and @code{changed} is a ``dummy'' theme that
1341of the Customize system. If you specify either of these as the 1343stores changes made outside of the Customize system.
1342@var{theme} argument, @code{deftheme} signals an error.
1343@end defmac 1344@end defmac
1344 1345
1345@defmac provide-theme theme 1346@defmac provide-theme theme
@@ -1387,7 +1388,7 @@ displays the source file and asks for confirmation from the user
1387before loading any non-built-in theme for the first time. 1388before loading any non-built-in theme for the first time.
1388 1389
1389 The following functions are useful for programmatically enabling and 1390 The following functions are useful for programmatically enabling and
1390disabling Custom themes: 1391disabling themes:
1391 1392
1392@defun custom-theme-p theme 1393@defun custom-theme-p theme
1393This function return a non-@code{nil} value if @var{theme} (a symbol) 1394This function return a non-@code{nil} value if @var{theme} (a symbol)
@@ -1400,14 +1401,11 @@ it returns @code{nil}.
1400This function loads the Custom theme named @var{theme} from its source 1401This function loads the Custom theme named @var{theme} from its source
1401file, looking for the source file in the directories specified by the 1402file, looking for the source file in the directories specified by the
1402variable @code{custom-theme-load-path}. @xref{Custom Themes,,, emacs, 1403variable @code{custom-theme-load-path}. @xref{Custom Themes,,, emacs,
1403The GNU Emacs Manual}. It also @dfn{enables} the theme, causing its 1404The GNU Emacs Manual}. It also @dfn{enables} the theme (unless the
1404variable and face settings to take effect. 1405optional argument @var{no-enable} is non-@code{nil}), causing its
1405 1406variable and face settings to take effect. It prompts the user for
1406If the optional argument @var{no-confirm} is non-@code{nil}, this 1407confirmation before loading the theme, unless the optional argument
1407skips prompting the user for confirmation before loading the theme. 1408@var{no-confirm} is non-@code{nil}.
1408
1409If the optional argument @var{no-enable} is non-@code{nil}, the theme
1410is loaded but not enabled.
1411@end deffn 1409@end deffn
1412 1410
1413@deffn Command enable-theme theme 1411@deffn Command enable-theme theme
diff --git a/doc/lispref/eval.texi b/doc/lispref/eval.texi
index 62de337a5e3..342c79e48e8 100644
--- a/doc/lispref/eval.texi
+++ b/doc/lispref/eval.texi
@@ -1,6 +1,6 @@
1@c -*-texinfo-*- 1@c -*-texinfo-*-
2@c This is part of the GNU Emacs Lisp Reference Manual. 2@c This is part of the GNU Emacs Lisp Reference Manual.
3@c Copyright (C) 1990-1994, 1998, 2001-2012 Free Software Foundation, Inc. 3@c Copyright (C) 1990-1994, 1998, 2001-2012 Free Software Foundation, Inc.
4@c See the file elisp.texi for copying conditions. 4@c See the file elisp.texi for copying conditions.
5@setfilename ../../info/eval 5@setfilename ../../info/eval
6@node Evaluation, Control Structures, Symbols, Top 6@node Evaluation, Control Structures, Symbols, Top
@@ -261,16 +261,13 @@ use @code{fset} to set the function cell of a symbol and
261into the function cell of @code{first}, and the symbol @code{first} into 261into the function cell of @code{first}, and the symbol @code{first} into
262the function cell of @code{erste}. 262the function cell of @code{erste}.
263 263
264@smallexample 264@example
265@group 265@group
266;; @r{Build this function cell linkage:} 266;; @r{Build this function cell linkage:}
267;; ------------- ----- ------- ------- 267;; ------------- ----- ------- -------
268;; | #<subr car> | <-- | car | <-- | first | <-- | erste | 268;; | #<subr car> | <-- | car | <-- | first | <-- | erste |
269;; ------------- ----- ------- ------- 269;; ------------- ----- ------- -------
270@end group 270@end group
271@end smallexample
272
273@smallexample
274@group 271@group
275(symbol-function 'car) 272(symbol-function 'car)
276 @result{} #<subr car> 273 @result{} #<subr car>
@@ -287,19 +284,19 @@ the function cell of @code{erste}.
287(erste '(1 2 3)) ; @r{Call the function referenced by @code{erste}.} 284(erste '(1 2 3)) ; @r{Call the function referenced by @code{erste}.}
288 @result{} 1 285 @result{} 1
289@end group 286@end group
290@end smallexample 287@end example
291 288
292 By contrast, the following example calls a function without any symbol 289 By contrast, the following example calls a function without any symbol
293function indirection, because the first element is an anonymous Lisp 290function indirection, because the first element is an anonymous Lisp
294function, not a symbol. 291function, not a symbol.
295 292
296@smallexample 293@example
297@group 294@group
298((lambda (arg) (erste arg)) 295((lambda (arg) (erste arg))
299 '(1 2 3)) 296 '(1 2 3))
300 @result{} 1 297 @result{} 1
301@end group 298@end group
302@end smallexample 299@end example
303 300
304@noindent 301@noindent
305Executing the function itself evaluates its body; this does involve 302Executing the function itself evaluates its body; this does involve
@@ -308,18 +305,18 @@ symbol function indirection when calling @code{erste}.
308 This form is rarely used and is now deprecated. Instead, you should write it 305 This form is rarely used and is now deprecated. Instead, you should write it
309as: 306as:
310 307
311@smallexample 308@example
312@group 309@group
313(funcall (lambda (arg) (erste arg)) 310(funcall (lambda (arg) (erste arg))
314 '(1 2 3)) 311 '(1 2 3))
315@end group 312@end group
316@end smallexample 313@end example
317or just 314or just
318@smallexample 315@example
319@group 316@group
320(let ((arg '(1 2 3))) (erste arg)) 317(let ((arg '(1 2 3))) (erste arg))
321@end group 318@end group
322@end smallexample 319@end example
323 320
324 The built-in function @code{indirect-function} provides an easy way to 321 The built-in function @code{indirect-function} provides an easy way to
325perform symbol function indirection explicitly. 322perform symbol function indirection explicitly.
@@ -342,12 +339,12 @@ loop in the chain of symbols.
342 339
343Here is how you could define @code{indirect-function} in Lisp: 340Here is how you could define @code{indirect-function} in Lisp:
344 341
345@smallexample 342@example
346(defun indirect-function (function) 343(defun indirect-function (function)
347 (if (symbolp function) 344 (if (symbolp function)
348 (indirect-function (symbol-function function)) 345 (indirect-function (symbol-function function))
349 function)) 346 function))
350@end smallexample 347@end example
351@end defun 348@end defun
352 349
353@node Function Forms 350@node Function Forms
diff --git a/doc/lispref/functions.texi b/doc/lispref/functions.texi
index 24fe9ed5e68..21f365efe56 100644
--- a/doc/lispref/functions.texi
+++ b/doc/lispref/functions.texi
@@ -398,7 +398,7 @@ after a @code{&rest} argument.
398 398
399 Here are some examples of argument lists and proper calls: 399 Here are some examples of argument lists and proper calls:
400 400
401@smallexample 401@example
402(funcall (lambda (n) (1+ n)) ; @r{One required:} 402(funcall (lambda (n) (1+ n)) ; @r{One required:}
403 1) ; @r{requires exactly one argument.} 403 1) ; @r{requires exactly one argument.}
404 @result{} 2 404 @result{} 2
@@ -410,7 +410,7 @@ after a @code{&rest} argument.
410 (+ n (apply '+ ns))) ; @r{1 or more arguments.} 410 (+ n (apply '+ ns))) ; @r{1 or more arguments.}
411 1 2 3 4 5) 411 1 2 3 4 5)
412 @result{} 15 412 @result{} 15
413@end smallexample 413@end example
414 414
415@node Function Documentation 415@node Function Documentation
416@subsection Documentation Strings of Functions 416@subsection Documentation Strings of Functions
@@ -821,7 +821,7 @@ char-table; that is, a list, a vector, a bool-vector, or a string. The
821result is always a list. The length of the result is the same as the 821result is always a list. The length of the result is the same as the
822length of @var{sequence}. For example: 822length of @var{sequence}. For example:
823 823
824@smallexample 824@example
825@group 825@group
826(mapcar 'car '((a b) (c d) (e f))) 826(mapcar 'car '((a b) (c d) (e f)))
827 @result{} (a c e) 827 @result{} (a c e)
@@ -853,7 +853,7 @@ Return the list of results."
853(mapcar* 'cons '(a b c) '(1 2 3 4)) 853(mapcar* 'cons '(a b c) '(1 2 3 4))
854 @result{} ((a . 1) (b . 2) (c . 3)) 854 @result{} ((a . 1) (b . 2) (c . 3))
855@end group 855@end group
856@end smallexample 856@end example
857@end defun 857@end defun
858 858
859@defun mapc function sequence 859@defun mapc function sequence
@@ -874,7 +874,7 @@ argument and return a string. The argument @var{sequence} can be any
874kind of sequence except a char-table; that is, a list, a vector, a 874kind of sequence except a char-table; that is, a list, a vector, a
875bool-vector, or a string. 875bool-vector, or a string.
876 876
877@smallexample 877@example
878@group 878@group
879(mapconcat 'symbol-name 879(mapconcat 'symbol-name
880 '(The cat in the hat) 880 '(The cat in the hat)
@@ -888,7 +888,7 @@ bool-vector, or a string.
888 "") 888 "")
889 @result{} "IBM.9111" 889 @result{} "IBM.9111"
890@end group 890@end group
891@end smallexample 891@end example
892@end defun 892@end defun
893 893
894@node Anonymous Functions 894@node Anonymous Functions
@@ -1189,18 +1189,18 @@ still allow the code to be byte compiled).
1189For instance, in old versions of Emacs the @code{sit-for} function 1189For instance, in old versions of Emacs the @code{sit-for} function
1190accepted three arguments, like this 1190accepted three arguments, like this
1191 1191
1192@smallexample 1192@example
1193 (sit-for seconds milliseconds nodisp) 1193 (sit-for seconds milliseconds nodisp)
1194@end smallexample 1194@end example
1195 1195
1196However, calling @code{sit-for} this way is considered obsolete 1196However, calling @code{sit-for} this way is considered obsolete
1197(@pxref{Waiting}). The old calling convention is deprecated like 1197(@pxref{Waiting}). The old calling convention is deprecated like
1198this: 1198this:
1199 1199
1200@smallexample 1200@example
1201(set-advertised-calling-convention 1201(set-advertised-calling-convention
1202 'sit-for '(seconds &optional nodisp)) 1202 'sit-for '(seconds &optional nodisp))
1203@end smallexample 1203@end example
1204@end defun 1204@end defun
1205 1205
1206@node Inline Functions 1206@node Inline Functions
@@ -1260,11 +1260,11 @@ indicates a real problem, but usually the functions in question are
1260defined in other files which would be loaded if that code is run. For 1260defined in other files which would be loaded if that code is run. For
1261example, byte-compiling @file{fortran.el} used to warn: 1261example, byte-compiling @file{fortran.el} used to warn:
1262 1262
1263@smallexample 1263@example
1264In end of data: 1264In end of data:
1265fortran.el:2152:1:Warning: the function `gud-find-c-expr' is not known 1265fortran.el:2152:1:Warning: the function `gud-find-c-expr' is not known
1266 to be defined. 1266 to be defined.
1267@end smallexample 1267@end example
1268 1268
1269In fact, @code{gud-find-c-expr} is only used in the function that 1269In fact, @code{gud-find-c-expr} is only used in the function that
1270Fortran mode uses for the local value of 1270Fortran mode uses for the local value of
@@ -1277,9 +1277,9 @@ visible. You do that with @code{declare-function}.
1277All you need to do is add a @code{declare-function} statement before the 1277All you need to do is add a @code{declare-function} statement before the
1278first use of the function in question: 1278first use of the function in question:
1279 1279
1280@smallexample 1280@example
1281(declare-function gud-find-c-expr "gud.el" nil) 1281(declare-function gud-find-c-expr "gud.el" nil)
1282@end smallexample 1282@end example
1283 1283
1284This says that @code{gud-find-c-expr} is defined in @file{gud.el} (the 1284This says that @code{gud-find-c-expr} is defined in @file{gud.el} (the
1285@samp{.el} can be omitted). The compiler takes for granted that that file 1285@samp{.el} can be omitted). The compiler takes for granted that that file
diff --git a/doc/lispref/loading.texi b/doc/lispref/loading.texi
index 3806ab15b8b..93cc7a4598c 100644
--- a/doc/lispref/loading.texi
+++ b/doc/lispref/loading.texi
@@ -251,31 +251,31 @@ for @code{PATH}; directory names are separated by @samp{:} (or
251current default directory. Here is an example of how to set 251current default directory. Here is an example of how to set
252@env{EMACSLOADPATH} variable from @command{sh}: 252@env{EMACSLOADPATH} variable from @command{sh}:
253 253
254@smallexample 254@example
255export EMACSLOADPATH 255export EMACSLOADPATH
256EMACSLOADPATH=/home/foo/.emacs.d/lisp:/opt/emacs/lisp 256EMACSLOADPATH=/home/foo/.emacs.d/lisp:/opt/emacs/lisp
257@end smallexample 257@end example
258 258
259@noindent 259@noindent
260Here is how to set it from @code{csh}: 260Here is how to set it from @code{csh}:
261 261
262@smallexample 262@example
263setenv EMACSLOADPATH /home/foo/.emacs.d/lisp:/opt/emacs/lisp 263setenv EMACSLOADPATH /home/foo/.emacs.d/lisp:/opt/emacs/lisp
264@end smallexample 264@end example
265 265
266 If @env{EMACSLOADPATH} is not set (which is usually the case), Emacs 266 If @env{EMACSLOADPATH} is not set (which is usually the case), Emacs
267initializes @code{load-path} with the following two directories: 267initializes @code{load-path} with the following two directories:
268 268
269@smallexample 269@example
270"/usr/local/share/emacs/@var{version}/site-lisp" 270"/usr/local/share/emacs/@var{version}/site-lisp"
271@end smallexample 271@end example
272 272
273@noindent 273@noindent
274and 274and
275 275
276@smallexample 276@example
277"/usr/local/share/emacs/site-lisp" 277"/usr/local/share/emacs/site-lisp"
278@end smallexample 278@end example
279 279
280@noindent 280@noindent
281The first one is for locally installed packages for a particular Emacs 281The first one is for locally installed packages for a particular Emacs
@@ -304,9 +304,9 @@ packages are installed, if any (@pxref{Packaging Basics}).
304 It is common to add code to one's init file (@pxref{Init File}) to 304 It is common to add code to one's init file (@pxref{Init File}) to
305add one or more directories to @code{load-path}. For example: 305add one or more directories to @code{load-path}. For example:
306 306
307@smallexample 307@example
308(push "~/.emacs.d/lisp" load-path) 308(push "~/.emacs.d/lisp" load-path)
309@end smallexample 309@end example
310 310
311 Dumping Emacs uses a special value of @code{load-path}. If the 311 Dumping Emacs uses a special value of @code{load-path}. If the
312value of @code{load-path} at the end of dumping is unchanged (that is, 312value of @code{load-path} at the end of dumping is unchanged (that is,
@@ -340,9 +340,9 @@ similarly-named file in a directory earlier on @code{load-path}.
340 340
341For instance, suppose @code{load-path} is set to 341For instance, suppose @code{load-path} is set to
342 342
343@smallexample 343@example
344 ("/opt/emacs/site-lisp" "/usr/share/emacs/23.3/lisp") 344 ("/opt/emacs/site-lisp" "/usr/share/emacs/23.3/lisp")
345@end smallexample 345@end example
346 346
347@noindent 347@noindent
348and that both these directories contain a file named @file{foo.el}. 348and that both these directories contain a file named @file{foo.el}.
@@ -535,24 +535,24 @@ it is executed while building Emacs.
535 The following example shows how @code{doctor} is prepared for 535 The following example shows how @code{doctor} is prepared for
536autoloading with a magic comment: 536autoloading with a magic comment:
537 537
538@smallexample 538@example
539;;;###autoload 539;;;###autoload
540(defun doctor () 540(defun doctor ()
541 "Switch to *doctor* buffer and start giving psychotherapy." 541 "Switch to *doctor* buffer and start giving psychotherapy."
542 (interactive) 542 (interactive)
543 (switch-to-buffer "*doctor*") 543 (switch-to-buffer "*doctor*")
544 (doctor-mode)) 544 (doctor-mode))
545@end smallexample 545@end example
546 546
547@noindent 547@noindent
548Here's what that produces in @file{loaddefs.el}: 548Here's what that produces in @file{loaddefs.el}:
549 549
550@smallexample 550@example
551(autoload (quote doctor) "doctor" "\ 551(autoload (quote doctor) "doctor" "\
552Switch to *doctor* buffer and start giving psychotherapy. 552Switch to *doctor* buffer and start giving psychotherapy.
553 553
554\(fn)" t nil) 554\(fn)" t nil)
555@end smallexample 555@end example
556 556
557@noindent 557@noindent
558@cindex @code{fn} in function's documentation string 558@cindex @code{fn} in function's documentation string
@@ -571,11 +571,11 @@ ordinary magic autoload comment would copy the whole definition into
571@code{loaddefs.el}. That is not desirable. You can put the desired 571@code{loaddefs.el}. That is not desirable. You can put the desired
572@code{autoload} call into @code{loaddefs.el} instead by writing this: 572@code{autoload} call into @code{loaddefs.el} instead by writing this:
573 573
574@smallexample 574@example
575;;;###autoload (autoload 'foo "myfile") 575;;;###autoload (autoload 'foo "myfile")
576(mydefunmacro foo 576(mydefunmacro foo
577 ...) 577 ...)
578@end smallexample 578@end example
579 579
580 You can use a non-default string as the autoload cookie and have the 580 You can use a non-default string as the autoload cookie and have the
581corresponding autoload calls written into a file whose name is 581corresponding autoload calls written into a file whose name is
@@ -680,7 +680,7 @@ file should call @code{provide} at the top level to add the feature to
680 For example, in @file{idlwave.el}, the definition for 680 For example, in @file{idlwave.el}, the definition for
681@code{idlwave-complete-filename} includes the following code: 681@code{idlwave-complete-filename} includes the following code:
682 682
683@smallexample 683@example
684(defun idlwave-complete-filename () 684(defun idlwave-complete-filename ()
685 "Use the comint stuff to complete a file name." 685 "Use the comint stuff to complete a file name."
686 (require 'comint) 686 (require 'comint)
@@ -688,7 +688,7 @@ file should call @code{provide} at the top level to add the feature to
688 (comint-completion-addsuffix nil) 688 (comint-completion-addsuffix nil)
689 ...) 689 ...)
690 (comint-dynamic-complete-filename))) 690 (comint-dynamic-complete-filename)))
691@end smallexample 691@end example
692 692
693@noindent 693@noindent
694The expression @code{(require 'comint)} loads the file @file{comint.el} 694The expression @code{(require 'comint)} loads the file @file{comint.el}
@@ -703,9 +703,9 @@ after the let exits.)
703 703
704The @file{comint.el} file contains the following top-level expression: 704The @file{comint.el} file contains the following top-level expression:
705 705
706@smallexample 706@example
707(provide 'comint) 707(provide 'comint)
708@end smallexample 708@end example
709 709
710@noindent 710@noindent
711This adds @code{comint} to the global @code{features} list, so that 711This adds @code{comint} to the global @code{features} list, so that
@@ -726,13 +726,13 @@ ensure that a file of definitions is loaded before it is byte-compiled
726by including a @code{provide} followed by a @code{require} for the same 726by including a @code{provide} followed by a @code{require} for the same
727feature, as in the following example. 727feature, as in the following example.
728 728
729@smallexample 729@example
730@group 730@group
731(provide 'my-feature) ; @r{Ignored by byte compiler,} 731(provide 'my-feature) ; @r{Ignored by byte compiler,}
732 ; @r{evaluated by @code{load}.} 732 ; @r{evaluated by @code{load}.}
733(require 'my-feature) ; @r{Evaluated by byte compiler.} 733(require 'my-feature) ; @r{Evaluated by byte compiler.}
734@end group 734@end group
735@end smallexample 735@end example
736 736
737@noindent 737@noindent
738The compiler ignores the @code{provide}, then processes the 738The compiler ignores the @code{provide}, then processes the
@@ -762,7 +762,7 @@ package, which might or might not be loaded, or might or might not be
762present in a given version. @xref{Network Feature Testing}, for 762present in a given version. @xref{Network Feature Testing}, for
763an example. 763an example.
764 764
765@smallexample 765@example
766features 766features
767 @result{} (bar bish) 767 @result{} (bar bish)
768 768
@@ -770,7 +770,7 @@ features
770 @result{} foo 770 @result{} foo
771features 771features
772 @result{} (foo bar bish) 772 @result{} (foo bar bish)
773@end smallexample 773@end example
774 774
775When a file is loaded to satisfy an autoload, and it stops due to an 775When a file is loaded to satisfy an autoload, and it stops due to an
776error in the evaluation of its contents, any function definitions or 776error in the evaluation of its contents, any function definitions or
diff --git a/doc/lispref/macros.texi b/doc/lispref/macros.texi
index b87e9f228f3..5cdcfae1e50 100644
--- a/doc/lispref/macros.texi
+++ b/doc/lispref/macros.texi
@@ -1,6 +1,6 @@
1@c -*-texinfo-*- 1@c -*-texinfo-*-
2@c This is part of the GNU Emacs Lisp Reference Manual. 2@c This is part of the GNU Emacs Lisp Reference Manual.
3@c Copyright (C) 1990-1995, 1998, 2001-2012 Free Software Foundation, Inc. 3@c Copyright (C) 1990-1995, 1998, 2001-2012 Free Software Foundation, Inc.
4@c See the file elisp.texi for copying conditions. 4@c See the file elisp.texi for copying conditions.
5@setfilename ../../info/macros 5@setfilename ../../info/macros
6@node Macros, Customization, Functions, Top 6@node Macros, Customization, Functions, Top
@@ -110,7 +110,7 @@ If @var{environment} is provided, it specifies an alist of macro
110definitions that shadow the currently defined macros. Byte compilation 110definitions that shadow the currently defined macros. Byte compilation
111uses this feature. 111uses this feature.
112 112
113@smallexample 113@example
114@group 114@group
115(defmacro inc (var) 115(defmacro inc (var)
116 (list 'setq var (list '1+ var))) 116 (list 'setq var (list '1+ var)))
@@ -132,7 +132,7 @@ uses this feature.
132(macroexpand '(inc2 r s)) 132(macroexpand '(inc2 r s))
133 @result{} (progn (inc r) (inc s)) ; @r{@code{inc} not expanded here.} 133 @result{} (progn (inc r) (inc s)) ; @r{@code{inc} not expanded here.}
134@end group 134@end group
135@end smallexample 135@end example
136@end defun 136@end defun
137 137
138 138
@@ -146,10 +146,10 @@ Repeating the example used for @code{macroexpand} above with
146@code{macroexpand-all}, we see that @code{macroexpand-all} @emph{does} 146@code{macroexpand-all}, we see that @code{macroexpand-all} @emph{does}
147expand the embedded calls to @code{inc}: 147expand the embedded calls to @code{inc}:
148 148
149@smallexample 149@example
150(macroexpand-all '(inc2 r s)) 150(macroexpand-all '(inc2 r s))
151 @result{} (progn (setq r (1+ r)) (setq s (1+ s))) 151 @result{} (progn (setq r (1+ r)) (setq s (1+ s)))
152@end smallexample 152@end example
153 153
154@end defun 154@end defun
155 155
@@ -333,7 +333,7 @@ following macro (used to facilitate iteration) illustrates the
333problem. This macro allows us to write a ``for'' loop construct. 333problem. This macro allows us to write a ``for'' loop construct.
334 334
335@findex for 335@findex for
336@smallexample 336@example
337@group 337@group
338(defmacro for (var from init to final do &rest body) 338(defmacro for (var from init to final do &rest body)
339 "Execute a simple \"for\" loop. 339 "Execute a simple \"for\" loop.
@@ -364,7 +364,7 @@ For example, (for i from 1 to 10 do (print i))."
364 @print{}3 9 364 @print{}3 9
365@result{} nil 365@result{} nil
366@end group 366@end group
367@end smallexample 367@end example
368 368
369@noindent 369@noindent
370The arguments @code{from}, @code{to}, and @code{do} in this macro are 370The arguments @code{from}, @code{to}, and @code{do} in this macro are
@@ -374,7 +374,7 @@ in those positions in the macro call.
374 374
375Here's an equivalent definition simplified through use of backquote: 375Here's an equivalent definition simplified through use of backquote:
376 376
377@smallexample 377@example
378@group 378@group
379(defmacro for (var from init to final do &rest body) 379(defmacro for (var from init to final do &rest body)
380 "Execute a simple \"for\" loop. 380 "Execute a simple \"for\" loop.
@@ -384,7 +384,7 @@ For example, (for i from 1 to 10 do (print i))."
384 ,@@body 384 ,@@body
385 (inc ,var)))) 385 (inc ,var))))
386@end group 386@end group
387@end smallexample 387@end example
388 388
389Both forms of this definition (with backquote and without) suffer from 389Both forms of this definition (with backquote and without) suffer from
390the defect that @var{final} is evaluated on every iteration. If 390the defect that @var{final} is evaluated on every iteration. If
@@ -399,7 +399,7 @@ producing an expansion that evaluates the argument expressions exactly
399once unless repeated evaluation is part of the intended purpose of the 399once unless repeated evaluation is part of the intended purpose of the
400macro. Here is a correct expansion for the @code{for} macro: 400macro. Here is a correct expansion for the @code{for} macro:
401 401
402@smallexample 402@example
403@group 403@group
404(let ((i 1) 404(let ((i 1)
405 (max 3)) 405 (max 3))
@@ -408,11 +408,11 @@ macro. Here is a correct expansion for the @code{for} macro:
408 (princ (format "%d %d" i square)) 408 (princ (format "%d %d" i square))
409 (inc i))) 409 (inc i)))
410@end group 410@end group
411@end smallexample 411@end example
412 412
413Here is a macro definition that creates this expansion: 413Here is a macro definition that creates this expansion:
414 414
415@smallexample 415@example
416@group 416@group
417(defmacro for (var from init to final do &rest body) 417(defmacro for (var from init to final do &rest body)
418 "Execute a simple for loop: (for i from 1 to 10 do (print i))." 418 "Execute a simple for loop: (for i from 1 to 10 do (print i))."
@@ -422,7 +422,7 @@ Here is a macro definition that creates this expansion:
422 ,@@body 422 ,@@body
423 (inc ,var)))) 423 (inc ,var))))
424@end group 424@end group
425@end smallexample 425@end example
426 426
427 Unfortunately, this fix introduces another problem, 427 Unfortunately, this fix introduces another problem,
428described in the following section. 428described in the following section.
@@ -435,7 +435,7 @@ described in the following section.
435follows to make the expansion evaluate the macro arguments the proper 435follows to make the expansion evaluate the macro arguments the proper
436number of times: 436number of times:
437 437
438@smallexample 438@example
439@group 439@group
440(defmacro for (var from init to final do &rest body) 440(defmacro for (var from init to final do &rest body)
441 "Execute a simple for loop: (for i from 1 to 10 do (print i))." 441 "Execute a simple for loop: (for i from 1 to 10 do (print i))."
@@ -447,14 +447,14 @@ number of times:
447 ,@@body 447 ,@@body
448 (inc ,var)))) 448 (inc ,var))))
449@end group 449@end group
450@end smallexample 450@end example
451@end ifnottex 451@end ifnottex
452 452
453 The new definition of @code{for} has a new problem: it introduces a 453 The new definition of @code{for} has a new problem: it introduces a
454local variable named @code{max} which the user does not expect. This 454local variable named @code{max} which the user does not expect. This
455causes trouble in examples such as the following: 455causes trouble in examples such as the following:
456 456
457@smallexample 457@example
458@group 458@group
459(let ((max 0)) 459(let ((max 0))
460 (for x from 0 to 10 do 460 (for x from 0 to 10 do
@@ -462,7 +462,7 @@ causes trouble in examples such as the following:
462 (if (< max this) 462 (if (< max this)
463 (setq max this))))) 463 (setq max this)))))
464@end group 464@end group
465@end smallexample 465@end example
466 466
467@noindent 467@noindent
468The references to @code{max} inside the body of the @code{for}, which 468The references to @code{max} inside the body of the @code{for}, which
@@ -478,7 +478,7 @@ put it into the program later. It will never appear anywhere except
478where put by @code{for}. Here is a definition of @code{for} that works 478where put by @code{for}. Here is a definition of @code{for} that works
479this way: 479this way:
480 480
481@smallexample 481@example
482@group 482@group
483(defmacro for (var from init to final do &rest body) 483(defmacro for (var from init to final do &rest body)
484 "Execute a simple for loop: (for i from 1 to 10 do (print i))." 484 "Execute a simple for loop: (for i from 1 to 10 do (print i))."
@@ -489,7 +489,7 @@ this way:
489 ,@@body 489 ,@@body
490 (inc ,var))))) 490 (inc ,var)))))
491@end group 491@end group
492@end smallexample 492@end example
493 493
494@noindent 494@noindent
495This creates an uninterned symbol named @code{max} and puts it in the 495This creates an uninterned symbol named @code{max} and puts it in the
diff --git a/doc/lispref/sequences.texi b/doc/lispref/sequences.texi
index 50f75da2de8..1a1160a34d7 100644
--- a/doc/lispref/sequences.texi
+++ b/doc/lispref/sequences.texi
@@ -248,7 +248,7 @@ The length of the array is fixed once you create it; you cannot
248change the length of an existing array. 248change the length of an existing array.
249 249
250@item 250@item
251For purposes of evaluation, the array is a constant---in other words, 251For purposes of evaluation, the array is a constant---i.e.,
252it evaluates to itself. 252it evaluates to itself.
253 253
254@item 254@item
diff --git a/doc/lispref/symbols.texi b/doc/lispref/symbols.texi
index f2ffc20f588..6148d76ca32 100644
--- a/doc/lispref/symbols.texi
+++ b/doc/lispref/symbols.texi
@@ -1,6 +1,6 @@
1@c -*-texinfo-*- 1@c -*-texinfo-*-
2@c This is part of the GNU Emacs Lisp Reference Manual. 2@c This is part of the GNU Emacs Lisp Reference Manual.
3@c Copyright (C) 1990-1995, 1998-1999, 2001-2012 Free Software Foundation, Inc. 3@c Copyright (C) 1990-1995, 1998-1999, 2001-2012 Free Software Foundation, Inc.
4@c See the file elisp.texi for copying conditions. 4@c See the file elisp.texi for copying conditions.
5@setfilename ../../info/symbols 5@setfilename ../../info/symbols
6@node Symbols, Evaluation, Hash Tables, Top 6@node Symbols, Evaluation, Hash Tables, Top
@@ -91,7 +91,7 @@ the contents of a symbol's function cell, use the function
91@code{symbol-function} (@pxref{Function Cells}). 91@code{symbol-function} (@pxref{Function Cells}).
92 92
93 The property list cell normally should hold a correctly formatted 93 The property list cell normally should hold a correctly formatted
94property list. To get a symbol's function cell, use the function 94property list. To get a symbol's property list, use the function
95@code{symbol-plist}. @xref{Property Lists}. 95@code{symbol-plist}. @xref{Property Lists}.
96 96
97 The function cell or the value cell may be @dfn{void}, which means 97 The function cell or the value cell may be @dfn{void}, which means
@@ -311,7 +311,7 @@ The argument @var{name} may also be a symbol; in that case,
311the function returns @var{name} if @var{name} is interned 311the function returns @var{name} if @var{name} is interned
312in the specified obarray, and otherwise @code{nil}. 312in the specified obarray, and otherwise @code{nil}.
313 313
314@smallexample 314@example
315(intern-soft "frazzle") ; @r{No such symbol exists.} 315(intern-soft "frazzle") ; @r{No such symbol exists.}
316 @result{} nil 316 @result{} nil
317(make-symbol "frazzle") ; @r{Create an uninterned one.} 317(make-symbol "frazzle") ; @r{Create an uninterned one.}
@@ -332,7 +332,7 @@ in the specified obarray, and otherwise @code{nil}.
332(eq sym 'frazzle) ; @r{And it is the same one.} 332(eq sym 'frazzle) ; @r{And it is the same one.}
333 @result{} t 333 @result{} t
334@end group 334@end group
335@end smallexample 335@end example
336@end defun 336@end defun
337 337
338@defvar obarray 338@defvar obarray
@@ -347,7 +347,7 @@ This function calls @var{function} once with each symbol in the obarray
347omitted, it defaults to the value of @code{obarray}, the standard 347omitted, it defaults to the value of @code{obarray}, the standard
348obarray for ordinary symbols. 348obarray for ordinary symbols.
349 349
350@smallexample 350@example
351(setq count 0) 351(setq count 0)
352 @result{} 0 352 @result{} 0
353(defun count-syms (s) 353(defun count-syms (s)
@@ -357,7 +357,7 @@ obarray for ordinary symbols.
357 @result{} nil 357 @result{} nil
358count 358count
359 @result{} 1871 359 @result{} 1871
360@end smallexample 360@end example
361 361
362See @code{documentation} in @ref{Accessing Documentation}, for another 362See @code{documentation} in @ref{Accessing Documentation}, for another
363example using @code{mapatoms}. 363example using @code{mapatoms}.
@@ -463,12 +463,12 @@ This function sets @var{symbol}'s property list to @var{plist}.
463Normally, @var{plist} should be a well-formed property list, but this is 463Normally, @var{plist} should be a well-formed property list, but this is
464not enforced. The return value is @var{plist}. 464not enforced. The return value is @var{plist}.
465 465
466@smallexample 466@example
467(setplist 'foo '(a 1 b (2 3) c nil)) 467(setplist 'foo '(a 1 b (2 3) c nil))
468 @result{} (a 1 b (2 3) c nil) 468 @result{} (a 1 b (2 3) c nil)
469(symbol-plist 'foo) 469(symbol-plist 'foo)
470 @result{} (a 1 b (2 3) c nil) 470 @result{} (a 1 b (2 3) c nil)
471@end smallexample 471@end example
472 472
473For symbols in special obarrays, which are not used for ordinary 473For symbols in special obarrays, which are not used for ordinary
474purposes, it may make sense to use the property list cell in a 474purposes, it may make sense to use the property list cell in a
@@ -493,7 +493,7 @@ This function puts @var{value} onto @var{symbol}'s property list under
493the property name @var{property}, replacing any previous property value. 493the property name @var{property}, replacing any previous property value.
494The @code{put} function returns @var{value}. 494The @code{put} function returns @var{value}.
495 495
496@smallexample 496@example
497(put 'fly 'verb 'transitive) 497(put 'fly 'verb 'transitive)
498 @result{}'transitive 498 @result{}'transitive
499(put 'fly 'noun '(a buzzing little bug)) 499(put 'fly 'noun '(a buzzing little bug))
@@ -502,14 +502,14 @@ The @code{put} function returns @var{value}.
502 @result{} transitive 502 @result{} transitive
503(symbol-plist 'fly) 503(symbol-plist 'fly)
504 @result{} (verb transitive noun (a buzzing little bug)) 504 @result{} (verb transitive noun (a buzzing little bug))
505@end smallexample 505@end example
506@end defun 506@end defun
507 507
508@node Other Plists 508@node Other Plists
509@subsection Property Lists Outside Symbols 509@subsection Property Lists Outside Symbols
510 510
511 These functions are useful for manipulating property lists 511 These functions are useful for manipulating property lists
512that are stored in places other than symbols: 512not stored in symbols:
513 513
514@defun plist-get plist property 514@defun plist-get plist property
515This returns the value of the @var{property} property stored in the 515This returns the value of the @var{property} property stored in the