Commit | Line | Data |
---|---|---|
b8d4c8d0 GM |
1 | @c -*-texinfo-*- |
2 | @c This is part of the GNU Emacs Lisp Reference Manual. | |
ab422c4d PE |
3 | @c Copyright (C) 1990-1993, 1999, 2001-2013 Free Software Foundation, |
4 | @c Inc. | |
b8d4c8d0 | 5 | @c See the file elisp.texi for copying conditions. |
ecc6530d | 6 | @node Standard Errors |
b8d4c8d0 GM |
7 | @appendix Standard Errors |
8 | @cindex standard errors | |
9 | ||
7e05b1ec | 10 | Here is a list of the more important error symbols in standard Emacs, |
b8d4c8d0 GM |
11 | grouped by concept. The list includes each symbol's message (on the |
12 | @code{error-message} property of the symbol) and a cross reference to a | |
13 | description of how the error can occur. | |
14 | ||
15 | Each error symbol has an @code{error-conditions} property that is a | |
16 | list of symbols. Normally this list includes the error symbol itself | |
17 | and the symbol @code{error}. Occasionally it includes additional | |
18 | symbols, which are intermediate classifications, narrower than | |
19 | @code{error} but broader than a single error symbol. For example, all | |
20 | the errors in accessing files have the condition @code{file-error}. If | |
21 | we do not say here that a certain error symbol has additional error | |
22 | conditions, that means it has none. | |
23 | ||
24 | As a special exception, the error symbol @code{quit} does not have the | |
25 | condition @code{error}, because quitting is not considered an error. | |
26 | ||
7e05b1ec | 27 | @c You can grep for "(put 'foo 'error-conditions ...) to find |
1df7defd | 28 | @c examples defined in Lisp. E.g., soap-client.el, sasl.el. |
7e05b1ec GM |
29 | Most of these error symbols are defined in C (mainly @file{data.c}), |
30 | but some are defined in Lisp. For example, the file @file{userlock.el} | |
31 | defines the @code{file-locked} and @code{file-supersession} errors. | |
32 | Several of the specialized Lisp libraries distributed with Emacs | |
33 | define their own error symbols. We do not attempt to list of all | |
34 | those here. | |
35 | ||
b8d4c8d0 GM |
36 | @xref{Errors}, for an explanation of how errors are generated and |
37 | handled. | |
38 | ||
39 | @table @code | |
b8d4c8d0 | 40 | @item error |
48de8b12 | 41 | The message is @samp{error}. @xref{Errors}. |
b8d4c8d0 GM |
42 | |
43 | @item quit | |
48de8b12 | 44 | The message is @samp{Quit}. @xref{Quitting}. |
b8d4c8d0 GM |
45 | |
46 | @item args-out-of-range | |
48de8b12 CY |
47 | The message is @samp{Args out of range}. This happens when trying to |
48 | access an element beyond the range of a sequence, buffer, or other | |
49 | container-like object. @xref{Sequences Arrays Vectors}, and | |
50 | @xref{Text}. | |
b8d4c8d0 GM |
51 | |
52 | @item arith-error | |
48de8b12 CY |
53 | The message is @samp{Arithmetic error}. This occurs when trying to |
54 | perform integer division by zero. @xref{Numeric Conversions}, and | |
b8d4c8d0 GM |
55 | @xref{Arithmetic Operations}. |
56 | ||
57 | @item beginning-of-buffer | |
48de8b12 | 58 | The message is @samp{Beginning of buffer}. @xref{Character Motion}. |
b8d4c8d0 GM |
59 | |
60 | @item buffer-read-only | |
48de8b12 | 61 | The message is @samp{Buffer is read-only}. @xref{Read Only Buffers}. |
b8d4c8d0 | 62 | |
4bb82fa8 | 63 | @item circular-list |
48de8b12 CY |
64 | The message is @samp{List contains a loop}. This happens when a |
65 | circular structure is encountered. @xref{Circular Objects}. | |
7e05b1ec GM |
66 | |
67 | @item cl-assertion-failed | |
48de8b12 | 68 | The message is @samp{Assertion failed}. This happens when the |
0d8e94e9 | 69 | @code{cl-assert} macro fails a test. @xref{Assertions,,, cl, Common Lisp |
48de8b12 | 70 | Extensions}. |
4bb82fa8 | 71 | |
b8d4c8d0 | 72 | @item coding-system-error |
48de8b12 CY |
73 | The message is @samp{Invalid coding system}. @xref{Lisp and Coding |
74 | Systems}. | |
b8d4c8d0 GM |
75 | |
76 | @item cyclic-function-indirection | |
48de8b12 CY |
77 | The message is @samp{Symbol's chain of function indirections contains |
78 | a loop}. @xref{Function Indirection}. | |
b8d4c8d0 GM |
79 | |
80 | @item cyclic-variable-indirection | |
48de8b12 CY |
81 | The message is @samp{Symbol's chain of variable indirections contains |
82 | a loop}. @xref{Variable Aliases}. | |
b8d4c8d0 | 83 | |
4bb82fa8 | 84 | @item dbus-error |
48de8b12 CY |
85 | The message is @samp{D-Bus error}. This is only defined if Emacs was |
86 | compiled with D-Bus support. @xref{Errors and Events,,, dbus, D-Bus | |
87 | integration in Emacs}. | |
4bb82fa8 | 88 | |
b8d4c8d0 | 89 | @item end-of-buffer |
48de8b12 | 90 | The message is @samp{End of buffer}. @xref{Character Motion}. |
b8d4c8d0 GM |
91 | |
92 | @item end-of-file | |
48de8b12 CY |
93 | The message is @samp{End of file during parsing}. Note that this is |
94 | not a subcategory of @code{file-error}, because it pertains to the | |
1df7defd | 95 | Lisp reader, not to file I/O@. @xref{Input Functions}. |
b8d4c8d0 GM |
96 | |
97 | @item file-already-exists | |
48de8b12 | 98 | This is a subcategory of @code{file-error}. @xref{Writing to Files}. |
b8d4c8d0 GM |
99 | |
100 | @item file-date-error | |
101 | This is a subcategory of @code{file-error}. It occurs when | |
102 | @code{copy-file} tries and fails to set the last-modification time of | |
48de8b12 | 103 | the output file. @xref{Changing Files}. |
b8d4c8d0 GM |
104 | |
105 | @item file-error | |
106 | We do not list the error-strings of this error and its subcategories, | |
107 | because the error message is normally constructed from the data items | |
108 | alone when the error condition @code{file-error} is present. Thus, | |
109 | the error-strings are not very relevant. However, these error symbols | |
110 | do have @code{error-message} properties, and if no data is provided, | |
48de8b12 | 111 | the @code{error-message} property @emph{is} used. @xref{Files}. |
b8d4c8d0 | 112 | |
7e05b1ec GM |
113 | @c jka-compr.el |
114 | @item compression-error | |
115 | This is a subcategory of @code{file-error}, which results from | |
48de8b12 | 116 | problems handling a compressed file. @xref{How Programs Do Loading}. |
7e05b1ec GM |
117 | |
118 | @c userlock.el | |
b8d4c8d0 | 119 | @item file-locked |
48de8b12 | 120 | This is a subcategory of @code{file-error}. @xref{File Locks}. |
b8d4c8d0 | 121 | |
7e05b1ec | 122 | @c userlock.el |
b8d4c8d0 | 123 | @item file-supersession |
48de8b12 | 124 | This is a subcategory of @code{file-error}. @xref{Modification Time}. |
b8d4c8d0 | 125 | |
7e05b1ec | 126 | @c net/ange-ftp.el |
b8d4c8d0 | 127 | @item ftp-error |
48de8b12 CY |
128 | This is a subcategory of @code{file-error}, which results from |
129 | problems in accessing a remote file using ftp. @xref{Remote Files,,, | |
130 | emacs, The GNU Emacs Manual}. | |
b8d4c8d0 GM |
131 | |
132 | @item invalid-function | |
48de8b12 | 133 | The message is @samp{Invalid function}. @xref{Function Indirection}. |
b8d4c8d0 GM |
134 | |
135 | @item invalid-read-syntax | |
48de8b12 CY |
136 | The message is @samp{Invalid read syntax}. @xref{Printed |
137 | Representation}. | |
b8d4c8d0 GM |
138 | |
139 | @item invalid-regexp | |
48de8b12 | 140 | The message is @samp{Invalid regexp}. @xref{Regular Expressions}. |
b8d4c8d0 | 141 | |
7e05b1ec | 142 | @c simple.el |
b8d4c8d0 | 143 | @item mark-inactive |
48de8b12 | 144 | The message is @samp{The mark is not active now}. @xref{The Mark}. |
b8d4c8d0 GM |
145 | |
146 | @item no-catch | |
48de8b12 | 147 | The message is @samp{No catch for tag}. @xref{Catch and Throw}. |
b8d4c8d0 | 148 | |
4bb82fa8 | 149 | @ignore |
7e05b1ec | 150 | @c Not actually used for anything? Probably definition should be removed. |
4bb82fa8 | 151 | @item protected-field |
735135f9 | 152 | The message is @samp{Attempt to modify a protected file}. |
4bb82fa8 GM |
153 | @end ignore |
154 | ||
b8d4c8d0 | 155 | @item scan-error |
48de8b12 CY |
156 | The message is @samp{Scan error}. This happens when certain |
157 | syntax-parsing functions find invalid syntax or mismatched | |
158 | parentheses. @xref{List Motion}, and @xref{Parsing Expressions}. | |
b8d4c8d0 GM |
159 | |
160 | @item search-failed | |
48de8b12 | 161 | The message is @samp{Search failed}. @xref{Searching and Matching}. |
b8d4c8d0 GM |
162 | |
163 | @item setting-constant | |
48de8b12 CY |
164 | The message is @samp{Attempt to set a constant symbol}. This happens |
165 | when attempting to assign values to @code{nil}, @code{t}, and keyword | |
166 | symbols. @xref{Constant Variables}. | |
b8d4c8d0 | 167 | |
7e05b1ec | 168 | @c simple.el |
b8d4c8d0 | 169 | @item text-read-only |
48de8b12 CY |
170 | The message is @samp{Text is read-only}. This is a subcategory of |
171 | @code{buffer-read-only}. @xref{Special Properties}. | |
b8d4c8d0 GM |
172 | |
173 | @item undefined-color | |
48de8b12 | 174 | The message is @samp{Undefined color}. @xref{Color Names}. |
b8d4c8d0 | 175 | |
38868ad7 GM |
176 | @item user-error |
177 | The message is the empty string. @xref{Signaling Errors}. | |
178 | ||
b8d4c8d0 | 179 | @item void-function |
48de8b12 | 180 | The message is @samp{Symbol's function definition is void}. |
b8d4c8d0 GM |
181 | @xref{Function Cells}. |
182 | ||
183 | @item void-variable | |
48de8b12 | 184 | The message is @samp{Symbol's value as variable is void}. |
b8d4c8d0 GM |
185 | @xref{Accessing Variables}. |
186 | ||
187 | @item wrong-number-of-arguments | |
48de8b12 CY |
188 | The message is @samp{Wrong number of arguments}. @xref{Classifying |
189 | Lists}. | |
b8d4c8d0 GM |
190 | |
191 | @item wrong-type-argument | |
48de8b12 | 192 | The message is @samp{Wrong type argument}. @xref{Type Predicates}. |
b8d4c8d0 GM |
193 | @end table |
194 | ||
48de8b12 | 195 | @ignore The following seem to be unused now. |
4bb82fa8 | 196 | The following kinds of error, which are classified as special cases of |
b8d4c8d0 | 197 | @code{arith-error}, can occur on certain systems for invalid use of |
4bb82fa8 | 198 | mathematical functions. @xref{Math Functions}. |
b8d4c8d0 GM |
199 | |
200 | @table @code | |
201 | @item domain-error | |
48de8b12 | 202 | The message is @samp{Arithmetic domain error}. |
b8d4c8d0 GM |
203 | |
204 | @item overflow-error | |
48de8b12 CY |
205 | The message is @samp{Arithmetic overflow error}. This is a subcategory |
206 | of @code{domain-error}. | |
b8d4c8d0 GM |
207 | |
208 | @item range-error | |
48de8b12 | 209 | The message is @code{Arithmetic range error}. |
b8d4c8d0 GM |
210 | |
211 | @item singularity-error | |
735135f9 | 212 | The message is @samp{Arithmetic singularity error}. This is a |
48de8b12 | 213 | subcategory of @code{domain-error}. |
b8d4c8d0 GM |
214 | |
215 | @item underflow-error | |
48de8b12 CY |
216 | The message is @samp{Arithmetic underflow error}. This is a |
217 | subcategory of @code{domain-error}. | |
b8d4c8d0 | 218 | @end table |
48de8b12 | 219 | @end ignore |