Function: edebug-signal

edebug-signal is a byte-compiled function defined in edebug.el.gz.

Signature

(edebug-signal SIGNAL-NAME SIGNAL-DATA)

Documentation

Signal an error. Args are SIGNAL-NAME, and associated DATA.

A signal name is a symbol with an error-conditions property that is a list of condition names. A handler for any of those names will get to handle this signal. The symbol error should always be one of them.

DATA should be a list. Its elements are printed as part of the error message. If the signal is handled, DATA is made available to the handler. See condition-case.

This is the Edebug replacement for the standard signal. It should only be active while Edebug is. It checks debug-on-error to see whether it should call the debugger. When execution is resumed, the error is signaled again.

Source Code

;; Defined in /usr/src/emacs/lisp/emacs-lisp/edebug.el.gz
(defvar edebug-outside-debug-on-quit) ; the value of debug-on-quit outside

;;; Handling signals

(defun edebug-signal (signal-name signal-data)
  "Signal an error.  Args are SIGNAL-NAME, and associated DATA.
A signal name is a symbol with an `error-conditions' property
that is a list of condition names.
A handler for any of those names will get to handle this signal.
The symbol `error' should always be one of them.

DATA should be a list.  Its elements are printed as part of the error message.
If the signal is handled, DATA is made available to the handler.
See `condition-case'.

This is the Edebug replacement for the standard `signal'.  It should
only be active while Edebug is.  It checks `debug-on-error' to see
whether it should call the debugger.  When execution is resumed, the
error is signaled again."
  (if (and (listp debug-on-error) (memq signal-name debug-on-error))
      (edebug 'error (cons signal-name signal-data))))