2007-09-06 04:25:08 +00:00
|
|
|
@c -*-texinfo-*-
|
|
|
|
@c This is part of the GNU Emacs Lisp Reference Manual.
|
2025-01-01 07:39:17 +00:00
|
|
|
@c Copyright (C) 1990--1993, 1999, 2001--2025 Free Software Foundation,
|
2013-01-01 09:11:05 +00:00
|
|
|
@c Inc.
|
2007-09-06 04:25:08 +00:00
|
|
|
@c See the file elisp.texi for copying conditions.
|
2012-05-26 18:34:14 -07:00
|
|
|
@node Standard Errors
|
2007-09-06 04:25:08 +00:00
|
|
|
@appendix Standard Errors
|
|
|
|
@cindex standard errors
|
|
|
|
|
* lisp/subr.el (define-error): New function.
* doc/lispref/control.texi (Signaling Errors): Refer to define-error.
(Error Symbols): Add `define-error'.
* doc/lispref/errors.texi (Standard Errors): Don't refer to `error-conditions'.
* lisp/progmodes/ada-xref.el (ada-error-file-not-found): Rename from
error-file-not-found and define with define-error.
* lisp/emacs-lisp/cl-lib.el (cl-assertion-failed): Move here from subr.el
and define with define-error.
* lisp/userlock.el (file-locked, file-supersession):
* lisp/simple.el (mark-inactive):
* lisp/progmodes/js.el (js-moz-bad-rpc, js-js-error):
* lisp/progmodes/ada-mode.el (ada-mode-errors):
* lisp/play/life.el (life-extinct):
* lisp/nxml/xsd-regexp.el (xsdre-invalid-regexp, xsdre-parse-error):
* lisp/nxml/xmltok.el (xmltok-markup-declaration-parse-error):
* lisp/nxml/rng-util.el (rng-error):
* lisp/nxml/rng-uri.el (rng-uri-error):
* lisp/nxml/rng-match.el (rng-compile-error):
* lisp/nxml/rng-cmpct.el (rng-c-incorrect-schema):
* lisp/nxml/nxml-util.el (nxml-error, nxml-file-parse-error):
* lisp/nxml/nxml-rap.el (nxml-scan-error):
* lisp/nxml/nxml-outln.el (nxml-outline-error):
* lisp/net/soap-client.el (soap-error):
* lisp/net/gnutls.el (gnutls-error):
* lisp/net/ange-ftp.el (ftp-error):
* lisp/mpc.el (mpc-proc-error):
* lisp/json.el (json-error, json-readtable-error, json-unknown-keyword)
(json-number-format, json-string-escape, json-string-format)
(json-key-format, json-object-format):
* lisp/jka-compr.el (compression-error):
* lisp/international/quail.el (quail-error):
* lisp/international/kkc.el (kkc-error):
* lisp/emacs-lisp/ert.el (ert-test-failed):
* lisp/calc/calc.el (calc-error, inexact-result, math-overflow)
(math-underflow):
* lisp/bookmark.el (bookmark-error-no-filename):
* lisp/epg.el (epg-error): Define with define-error.
2013-08-09 17:22:44 -04:00
|
|
|
Here is a list of the more important error symbols in standard Emacs, grouped
|
|
|
|
by concept. The list includes each symbol's message and a cross reference
|
|
|
|
to a description of how the error can occur.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2018-05-27 19:03:10 +02:00
|
|
|
Each error symbol has a set of parent error conditions that is a
|
2007-09-06 04:25:08 +00:00
|
|
|
list of symbols. Normally this list includes the error symbol itself
|
|
|
|
and the symbol @code{error}. Occasionally it includes additional
|
|
|
|
symbols, which are intermediate classifications, narrower than
|
|
|
|
@code{error} but broader than a single error symbol. For example, all
|
|
|
|
the errors in accessing files have the condition @code{file-error}. If
|
|
|
|
we do not say here that a certain error symbol has additional error
|
|
|
|
conditions, that means it has none.
|
|
|
|
|
2021-07-20 14:36:45 +02:00
|
|
|
As a special exception, the error symbols @code{quit} and
|
|
|
|
@code{minibuffer-quit} don't have the condition @code{error}, because
|
|
|
|
quitting is not considered an error.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
Most of these error symbols are defined in C (mainly @file{data.c}),
|
|
|
|
but some are defined in Lisp. For example, the file @file{userlock.el}
|
|
|
|
defines the @code{file-locked} and @code{file-supersession} errors.
|
|
|
|
Several of the specialized Lisp libraries distributed with Emacs
|
|
|
|
define their own error symbols. We do not attempt to list of all
|
|
|
|
those here.
|
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@xref{Errors}, for an explanation of how errors are generated and
|
|
|
|
handled.
|
|
|
|
|
|
|
|
@table @code
|
|
|
|
@item error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{error}. @xref{Errors}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item quit
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Quit}. @xref{Quitting}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2021-07-20 14:36:45 +02:00
|
|
|
@item minibuffer-quit
|
|
|
|
The message is @samp{Quit}. This is a subcategory of @code{quit}.
|
|
|
|
@xref{Quitting}.
|
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item args-out-of-range
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Args out of range}. This happens when trying to
|
|
|
|
access an element beyond the range of a sequence, buffer, or other
|
2019-10-09 12:29:21 +03:00
|
|
|
container-like object. @xref{Sequences Arrays Vectors}, and see
|
|
|
|
@ref{Text}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item arith-error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Arithmetic error}. This occurs when trying to
|
|
|
|
perform integer division by zero. @xref{Numeric Conversions}, and
|
2019-10-09 12:29:21 +03:00
|
|
|
see @ref{Arithmetic Operations}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item beginning-of-buffer
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Beginning of buffer}. @xref{Character Motion}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item buffer-read-only
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Buffer is read-only}. @xref{Read Only Buffers}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-24 00:28:42 -08:00
|
|
|
@item circular-list
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{List contains a loop}. This happens when a
|
|
|
|
circular structure is encountered. @xref{Circular Objects}.
|
2012-02-25 12:59:46 -08:00
|
|
|
|
|
|
|
@item cl-assertion-failed
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Assertion failed}. This happens when the
|
2012-10-31 16:59:04 -04:00
|
|
|
@code{cl-assert} macro fails a test. @xref{Assertions,,, cl, Common Lisp
|
2012-09-30 17:18:38 +08:00
|
|
|
Extensions}.
|
2012-02-24 00:28:42 -08:00
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item coding-system-error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Invalid coding system}. @xref{Lisp and Coding
|
|
|
|
Systems}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item cyclic-function-indirection
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Symbol's chain of function indirections contains
|
|
|
|
a loop}. @xref{Function Indirection}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item cyclic-variable-indirection
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Symbol's chain of variable indirections contains
|
|
|
|
a loop}. @xref{Variable Aliases}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-24 00:28:42 -08:00
|
|
|
@item dbus-error
|
Clean up D-Bus documentation (bug#41744)
* doc/lispref/errors.texi (Standard Errors): The error symbol
dbus-error is defined even when Emacs is built without D-Bus.
* doc/misc/dbus.texi (Bus Names, Introspection)
(Nodes and Interfaces, Methods and Signal)
(Properties and Annotations, Arguments and Signatures)
(Synchronous Methods, Receiving Method Calls, Signals)
(Alternative Buses, Errors and Events): Clarify wording. Fix
indentation of and simplify examples where possible. Improve
Texinfo markup and cross-referencing where possible.
(Type Conversion): Ditto. Remove mentions of Emacs' fixnum range
now that we have bignums.
* lisp/net/dbus.el (dbus-return-values-table)
(dbus-call-method-asynchronously, dbus-send-signal)
(dbus-register-signal, dbus-register-method)
(dbus-string-to-byte-array, dbus-byte-array-to-string)
(dbus-escape-as-identifier, dbus-check-event, dbus-event-bus-name)
(dbus-event-message-type, dbus-event-serial-number)
(dbus-event-service-name, dbus-event-path-name)
(dbus-event-interface-name, dbus-event-member-name)
(dbus-list-activatable-names, dbus-list-queued-owners, dbus-ping)
(dbus-introspect-get-interface-names, dbus-introspect-get-interface)
(dbus-introspect-get-method, dbus-introspect-get-signal)
(dbus-introspect-get-property, dbus-introspect-get-annotation-names)
(dbus-introspect-get-annotation, dbus-introspect-get-argument-names)
(dbus-introspect-get-argument, dbus-introspect-get-signature)
(dbus-set-property, dbus-register-property)
(dbus-get-all-managed-objects, dbus-init-bus): Clarify docstring and
improve formatting where possible.
(dbus-call-method): Ditto. Remove mentions of Emacs' fixnum range
now that we have bignums.
2020-06-06 00:58:37 +01:00
|
|
|
The message is @samp{D-Bus error}. @xref{Errors and Events,,, dbus,
|
|
|
|
D-Bus integration in Emacs}.
|
2012-02-24 00:28:42 -08:00
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item end-of-buffer
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{End of buffer}. @xref{Character Motion}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item end-of-file
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{End of file during parsing}. Note that this is
|
|
|
|
not a subcategory of @code{file-error}, because it pertains to the
|
2012-12-05 14:27:56 -08:00
|
|
|
Lisp reader, not to file I/O@. @xref{Input Functions}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item file-already-exists
|
2012-09-30 17:18:38 +08:00
|
|
|
This is a subcategory of @code{file-error}. @xref{Writing to Files}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2021-12-19 17:29:40 +02:00
|
|
|
@item permission-denied
|
|
|
|
This is a subcategory of @code{file-error}, which occurs when the OS
|
|
|
|
doesn't allow Emacs to access a file or a directory for some reason.
|
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item file-date-error
|
|
|
|
This is a subcategory of @code{file-error}. It occurs when
|
|
|
|
@code{copy-file} tries and fails to set the last-modification time of
|
2012-09-30 17:18:38 +08:00
|
|
|
the output file. @xref{Changing Files}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item file-error
|
|
|
|
We do not list the error-strings of this error and its subcategories,
|
|
|
|
because the error message is normally constructed from the data items
|
|
|
|
alone when the error condition @code{file-error} is present. Thus,
|
|
|
|
the error-strings are not very relevant. However, these error symbols
|
|
|
|
do have @code{error-message} properties, and if no data is provided,
|
2012-09-30 17:18:38 +08:00
|
|
|
the @code{error-message} property @emph{is} used. @xref{Files}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2016-10-21 13:04:02 -07:00
|
|
|
@item file-missing
|
|
|
|
This is a subcategory of @code{file-error}. It occurs when an
|
|
|
|
operation attempts to act on a file that is missing. @xref{Changing
|
|
|
|
Files}.
|
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
@c jka-compr.el
|
|
|
|
@item compression-error
|
|
|
|
This is a subcategory of @code{file-error}, which results from
|
2012-09-30 17:18:38 +08:00
|
|
|
problems handling a compressed file. @xref{How Programs Do Loading}.
|
2012-02-25 12:59:46 -08:00
|
|
|
|
|
|
|
@c userlock.el
|
2007-09-06 04:25:08 +00:00
|
|
|
@item file-locked
|
2012-09-30 17:18:38 +08:00
|
|
|
This is a subcategory of @code{file-error}. @xref{File Locks}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
@c userlock.el
|
2007-09-06 04:25:08 +00:00
|
|
|
@item file-supersession
|
2012-09-30 17:18:38 +08:00
|
|
|
This is a subcategory of @code{file-error}. @xref{Modification Time}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2013-07-22 11:19:00 +02:00
|
|
|
@c filenotify.el
|
|
|
|
@item file-notify-error
|
|
|
|
This is a subcategory of @code{file-error}. It happens, when a file
|
2013-07-24 15:10:38 +02:00
|
|
|
could not be watched for changes. @xref{File Notifications}.
|
2013-07-22 11:19:00 +02:00
|
|
|
|
2020-12-14 19:30:01 +01:00
|
|
|
@item remote-file-error
|
|
|
|
This is a subcategory of @code{file-error}, which results from
|
|
|
|
problems in accessing a remote file. @xref{Remote Files,,, emacs, The
|
|
|
|
GNU Emacs Manual}. Often, this error appears when timers, process
|
|
|
|
filters, process sentinels or special events in general try to access
|
|
|
|
a remote file, and collide with another remote file operation. In
|
2020-12-14 13:51:22 -08:00
|
|
|
general it is a good idea to write a bug report.
|
|
|
|
@xref{Bugs,,, emacs, The GNU Emacs Manual}.
|
2020-12-14 19:30:01 +01:00
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
@c net/ange-ftp.el
|
2007-09-06 04:25:08 +00:00
|
|
|
@item ftp-error
|
2020-12-14 19:30:01 +01:00
|
|
|
This is a subcategory of @code{remote-file-error}, which results from
|
2012-09-30 17:18:38 +08:00
|
|
|
problems in accessing a remote file using ftp. @xref{Remote Files,,,
|
|
|
|
emacs, The GNU Emacs Manual}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item invalid-function
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Invalid function}. @xref{Function Indirection}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item invalid-read-syntax
|
2019-08-23 20:42:45 +02:00
|
|
|
The message is usually @samp{Invalid read syntax}. @xref{Printed
|
|
|
|
Representation}. This error can also be raised by commands like
|
|
|
|
@code{eval-expression} when there's text following an expression. In
|
|
|
|
that case, the message is @samp{Trailing garbage following expression}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item invalid-regexp
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Invalid regexp}. @xref{Regular Expressions}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
@c simple.el
|
2007-09-06 04:25:08 +00:00
|
|
|
@item mark-inactive
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{The mark is not active now}. @xref{The Mark}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item no-catch
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{No catch for tag}. @xref{Catch and Throw}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-24 00:28:42 -08:00
|
|
|
@ignore
|
2012-02-25 12:59:46 -08:00
|
|
|
@c Not actually used for anything? Probably definition should be removed.
|
2012-02-24 00:28:42 -08:00
|
|
|
@item protected-field
|
2012-10-04 22:57:24 -07:00
|
|
|
The message is @samp{Attempt to modify a protected file}.
|
2012-02-24 00:28:42 -08:00
|
|
|
@end ignore
|
|
|
|
|
2018-08-22 19:30:24 -07:00
|
|
|
@item range-error
|
|
|
|
The message is @code{Arithmetic range error}.
|
2019-11-04 23:17:06 -08:00
|
|
|
|
|
|
|
@item overflow-error
|
|
|
|
The message is @samp{Arithmetic overflow error}. This is a subcategory
|
|
|
|
of @code{range-error}.
|
2018-08-22 19:30:24 -07:00
|
|
|
This can happen with integers exceeding the @code{integer-width} limit.
|
|
|
|
@xref{Integer Basics}.
|
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item scan-error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Scan error}. This happens when certain
|
|
|
|
syntax-parsing functions find invalid syntax or mismatched
|
2014-04-09 09:58:08 -07:00
|
|
|
parentheses. Conventionally raised with three argument: a
|
|
|
|
human-readable error message, the start of the obstacle that cannot be
|
|
|
|
moved over, and the end of the obstacle. @xref{List Motion}, and
|
2019-10-09 12:29:21 +03:00
|
|
|
see @ref{Parsing Expressions}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item search-failed
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Search failed}. @xref{Searching and Matching}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item setting-constant
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Attempt to set a constant symbol}. This happens
|
2017-11-26 20:23:15 +02:00
|
|
|
when attempting to assign values to @code{nil}, @code{t},
|
|
|
|
@code{most-positive-fixnum}, @code{most-negative-fixnum}, and keyword
|
|
|
|
symbols. It also happens when attempting to assign values to
|
|
|
|
@code{enable-multibyte-characters} and some other symbols whose direct
|
|
|
|
assignment is not allowed for some reason. @xref{Constant Variables}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-02-25 12:59:46 -08:00
|
|
|
@c simple.el
|
2007-09-06 04:25:08 +00:00
|
|
|
@item text-read-only
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Text is read-only}. This is a subcategory of
|
|
|
|
@code{buffer-read-only}. @xref{Special Properties}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item undefined-color
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Undefined color}. @xref{Color Names}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
2012-11-10 16:37:40 -08:00
|
|
|
@item user-error
|
|
|
|
The message is the empty string. @xref{Signaling Errors}.
|
|
|
|
|
2017-04-01 09:34:04 -04:00
|
|
|
@item user-search-failed
|
|
|
|
This is like @samp{search-failed}, but doesn't trigger the debugger,
|
2019-10-09 12:29:21 +03:00
|
|
|
like @samp{user-error}. @xref{Signaling Errors}, and see @ref{Searching
|
|
|
|
and Matching}. This is used for searching in Info files, see @ref{Search
|
2017-04-01 09:34:04 -04:00
|
|
|
Text,,,info,Info}.
|
|
|
|
|
2007-09-06 04:25:08 +00:00
|
|
|
@item void-function
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Symbol's function definition is void}.
|
2007-09-06 04:25:08 +00:00
|
|
|
@xref{Function Cells}.
|
|
|
|
|
|
|
|
@item void-variable
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Symbol's value as variable is void}.
|
2007-09-06 04:25:08 +00:00
|
|
|
@xref{Accessing Variables}.
|
|
|
|
|
|
|
|
@item wrong-number-of-arguments
|
2016-10-08 17:16:33 +03:00
|
|
|
The message is @samp{Wrong number of arguments}. @xref{Argument List}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item wrong-type-argument
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Wrong type argument}. @xref{Type Predicates}.
|
2019-10-29 21:42:33 +01:00
|
|
|
|
|
|
|
@item unknown-image-type
|
|
|
|
The message is @samp{Cannot determine image type}. @xref{Images}.
|
2021-01-12 15:12:28 +01:00
|
|
|
|
|
|
|
@item inhibited-interaction
|
|
|
|
The message is @samp{User interaction while inhibited}. This error is
|
2022-11-18 13:06:55 +01:00
|
|
|
signaled when @code{inhibit-interaction} is non-@code{nil} and a user
|
2021-01-12 15:12:28 +01:00
|
|
|
interaction function (like @code{read-from-minibuffer}) is called.
|
2007-09-06 04:25:08 +00:00
|
|
|
@end table
|
|
|
|
|
2023-10-22 12:21:08 +03:00
|
|
|
@c The following seem to be unused now.
|
|
|
|
@ignore
|
2012-02-24 00:28:42 -08:00
|
|
|
The following kinds of error, which are classified as special cases of
|
2007-09-06 04:25:08 +00:00
|
|
|
@code{arith-error}, can occur on certain systems for invalid use of
|
2012-02-24 00:28:42 -08:00
|
|
|
mathematical functions. @xref{Math Functions}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@table @code
|
|
|
|
@item domain-error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Arithmetic domain error}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item singularity-error
|
2012-10-04 22:57:24 -07:00
|
|
|
The message is @samp{Arithmetic singularity error}. This is a
|
2012-09-30 17:18:38 +08:00
|
|
|
subcategory of @code{domain-error}.
|
2007-09-06 04:25:08 +00:00
|
|
|
|
|
|
|
@item underflow-error
|
2012-09-30 17:18:38 +08:00
|
|
|
The message is @samp{Arithmetic underflow error}. This is a
|
|
|
|
subcategory of @code{domain-error}.
|
2007-09-06 04:25:08 +00:00
|
|
|
@end table
|
2012-09-30 17:18:38 +08:00
|
|
|
@end ignore
|