? lib-src/cl-ec-new.cmd ? site-lisp/subdirs.el Index: lisp/autorevert.el =================================================================== RCS file: /sources/emacs/emacs/lisp/autorevert.el,v retrieving revision 1.69 diff -b -u -r1.69 autorevert.el --- lisp/autorevert.el 2 Aug 2009 17:20:39 -0000 1.69 +++ lisp/autorevert.el 28 Nov 2009 01:41:23 -0000 @@ -334,7 +334,7 @@ (when auto-revert-tail-mode (unless buffer-file-name (auto-revert-tail-mode 0) - (error "This buffer is not visiting a file")) + (user-error "This buffer is not visiting a file")) (if (and (buffer-modified-p) (zerop auto-revert-tail-pos) ; library was loaded only after finding file (not (y-or-n-p "Buffer is modified, so tail offset may be wrong. Proceed? "))) Index: lisp/bindings.el =================================================================== RCS file: /sources/emacs/emacs/lisp/bindings.el,v retrieving revision 1.234 diff -b -u -r1.234 bindings.el --- lisp/bindings.el 15 Nov 2009 20:25:58 -0000 1.234 +++ lisp/bindings.el 28 Nov 2009 01:18:40 -0000 @@ -643,21 +643,21 @@ `(beginning-of-line beginning-of-buffer end-of-line end-of-buffer end-of-file buffer-read-only file-supersession - ,(purecopy "^Previous command was not a yank$") - ,(purecopy "^Minibuffer window is not active$") - ,(purecopy "^No previous history search regexp$") - ,(purecopy "^No later matching history item$") - ,(purecopy "^No earlier matching history item$") - ,(purecopy "^End of history; no default available$") - ,(purecopy "^End of defaults; no next item$") - ,(purecopy "^Beginning of history; no preceding item$") - ,(purecopy "^No recursive edit is in progress$") - ,(purecopy "^Changes to be undone are outside visible portion of buffer$") - ,(purecopy "^No undo information in this buffer$") - ,(purecopy "^No further undo information") - ,(purecopy "^Save not confirmed$") - ,(purecopy "^Recover-file cancelled\\.$") - ,(purecopy "^Cannot switch buffers in a dedicated window$") + ;;,(purecopy "^Previous command was not a yank$") + ;;,(purecopy "^Minibuffer window is not active$") + ;;,(purecopy "^No previous history search regexp$") + ;;,(purecopy "^No later matching history item$") + ;;,(purecopy "^No earlier matching history item$") + ;;,(purecopy "^End of history; no default available$") + ;;,(purecopy "^End of defaults; no next item$") + ;;,(purecopy "^Beginning of history; no preceding item$") + ;;,(purecopy "^No recursive edit is in progress$") + ;;,(purecopy "^Changes to be undone are outside visible portion of buffer$") + ;;,(purecopy "^No undo information in this buffer$") + ;;,(purecopy "^No further undo information") + ;;,(purecopy "^Save not confirmed$") + ;;,(purecopy "^Recover-file cancelled\\.$") + ;;,(purecopy "^Cannot switch buffers in a dedicated window$") )) Index: lisp/chistory.el =================================================================== RCS file: /sources/emacs/emacs/lisp/chistory.el,v retrieving revision 1.30 diff -b -u -r1.30 chistory.el --- lisp/chistory.el 13 Nov 2009 22:19:50 -0000 1.30 +++ lisp/chistory.el 28 Nov 2009 01:47:12 -0000 @@ -57,7 +57,7 @@ (setq what (car history)) (setq history (cdr history)))) (if (not what) - (error "Command history exhausted") + (user-error "Command history exhausted") ;; Try to remove any useless command history element for this command. (if (eq (car (car command-history)) 'repeat-matching-complex-command) (setq command-history (cdr command-history))) Index: lisp/comint.el =================================================================== RCS file: /sources/emacs/emacs/lisp/comint.el,v retrieving revision 1.400 diff -b -u -r1.400 comint.el --- lisp/comint.el 23 Nov 2009 20:31:11 -0000 1.400 +++ lisp/comint.el 27 Nov 2009 23:01:03 -0000 @@ -1041,10 +1041,10 @@ (defun comint-search-arg (arg) ;; First make sure there is a ring and that we are after the process mark (cond ((not (comint-after-pmark-p)) - (error "Not at command line")) + (user-error "Not at command line")) ((or (null comint-input-ring) (ring-empty-p comint-input-ring)) - (error "Empty input ring")) + (user-error "Empty input ring")) ((zerop arg) ;; arg of zero resets search from beginning, and uses arg of 1 (setq comint-input-ring-index nil) @@ -1111,7 +1111,7 @@ Moves relative to START, or `comint-input-ring-index'." (if (or (not (ring-p comint-input-ring)) (ring-empty-p comint-input-ring)) - (error "No history")) + (user-error "No history")) (let* ((len (ring-length comint-input-ring)) (motion (if (> arg 0) 1 -1)) (n (mod (- (or start (comint-search-start arg)) motion) len)) @@ -1151,7 +1151,7 @@ (let ((pos (comint-previous-matching-input-string-position regexp n))) ;; Has a match been found? (if (null pos) - (error "Not found") + (user-error "Not found") ;; If leaving the edit line, save partial input (if (null comint-input-ring-index) ;not yet on ring (setq comint-stored-incomplete-input @@ -1316,7 +1316,7 @@ (goto-char (match-beginning 0)) (if (not (search-forward old pos t)) (or silent - (error "Not found")) + (user-error "Not found")) (replace-match new t t) (message "History item: substituted")))) (t @@ -1715,7 +1715,7 @@ (interactive) ;; Note that the input string does not include its terminal newline. (let ((proc (get-buffer-process (current-buffer)))) - (if (not proc) (error "Current buffer has no process") + (if (not proc) (user-error "Current buffer has no process") (widen) (let* ((pmark (process-mark proc)) (intxt (if (>= (point) (marker-position pmark)) @@ -2130,7 +2130,7 @@ (let ((input (funcall comint-get-old-input)) (process (get-buffer-process (current-buffer)))) (if (not process) - (error "Current buffer has no process") + (user-error "Current buffer has no process") (goto-char (process-mark process)) (insert input)))) @@ -2439,7 +2439,7 @@ (save-excursion (while (/= n 0) (unless (re-search-backward regexp nil t dir) - (error "Not found")) + (user-error "Not found")) (when (eq (get-char-property (point) 'field) 'input) (setq n (- n dir)))) (field-beginning)))) @@ -3261,7 +3261,7 @@ from input that has not yet been sent." (interactive) (let ((proc (or (get-buffer-process (current-buffer)) - (error "Current buffer has no process")))) + (user-error "Current buffer has no process")))) (goto-char (process-mark proc)) (when (called-interactively-p 'interactive) (message "Point is now at the process mark")))) @@ -3286,7 +3286,7 @@ "Set the process mark at point." (interactive) (let ((proc (or (get-buffer-process (current-buffer)) - (error "Current buffer has no process")))) + (user-error "Current buffer has no process")))) (set-marker (process-mark proc) (point)) (message "Process mark set"))) @@ -3639,11 +3639,12 @@ results)) results))) -(dolist (x '("^Not at command line$" - "^Empty input ring$" - "^No history$" - "^Not found$" ; Too common? - "^Current buffer has no process$")) +(dolist (x '(;;"^Not at command line$" + ;;"^Empty input ring$" + ;;"^No history$" + ;;"^Not found$" ; Too common? + ;;"^Current buffer has no process$" + )) (add-to-list 'debug-ignored-errors x)) Index: lisp/completion.el =================================================================== RCS file: /sources/emacs/emacs/lisp/completion.el,v retrieving revision 1.70 diff -b -u -r1.70 completion.el --- lisp/completion.el 2 Oct 2009 03:48:39 -0000 1.70 +++ lisp/completion.el 27 Nov 2009 23:03:17 -0000 @@ -1301,7 +1301,7 @@ (defun check-completion-length (string) (if (< (length string) completion-min-length) - (error "The string `%s' is too short to be saved as a completion" + (user-error "The string `%s' is too short to be saved as a completion" string) (list string))) @@ -2464,8 +2464,9 @@ (defvaralias 'cmpl-syntax-table 'completion-syntax-table) (defalias 'initialize-completions 'completion-initialize) -(dolist (x '("^To complete, the point must be after a symbol at least [0-9]* character long\\.$" - "^The string \".*\" is too short to be saved as a completion\\.$")) +(dolist (x '(;;"^To complete, the point must be after a symbol at least [0-9]* character long\\.$" + ;;"^The string \".*\" is too short to be saved as a completion\\.$" + )) (add-to-list 'debug-ignored-errors x)) (provide 'completion) Index: lisp/cus-edit.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cus-edit.el,v retrieving revision 1.369 diff -b -u -r1.369 cus-edit.el --- lisp/cus-edit.el 14 Nov 2009 19:08:45 -0000 1.369 +++ lisp/cus-edit.el 27 Nov 2009 23:49:17 -0000 @@ -1111,7 +1111,7 @@ "Customize SYMBOL, which must be a user option variable." (interactive (custom-variable-prompt)) (unless symbol - (error "No variable specified")) + (user-error "No variable specified")) (let ((basevar (indirect-variable symbol))) (custom-buffer-create (list (list basevar 'custom-variable)) (format "*Customize Option: %s*" @@ -1128,7 +1128,7 @@ Show the buffer in another window, but don't select it." (interactive (custom-variable-prompt)) (unless symbol - (error "No variable specified")) + (user-error "No variable specified")) (let ((basevar (indirect-variable symbol))) (custom-buffer-create-other-window (list (list basevar 'custom-variable)) @@ -1230,7 +1230,7 @@ (if found (custom-buffer-create (custom-sort-items found t 'first) "*Customize Changed Options*") - (error "No user option defaults have been changed since Emacs %s" + (user-error "No user option defaults have been changed since Emacs %s" since-version)))) (defun customize-package-emacs-version (symbol package-version) @@ -1304,7 +1304,7 @@ (if (get face 'face-alias) (setq face (get face 'face-alias))) (unless (facep face) - (error "Invalid face %S" face)) + (user-error "Invalid face %S" face)) (custom-buffer-create (list (list face 'custom-face)) (format "*Customize Face: %s*" @@ -1340,7 +1340,7 @@ (boundp symbol) (push (list symbol 'custom-variable) found)))) (if (not found) - (error "No user options are set but unsaved") + (user-error "No user options are set but unsaved") (custom-buffer-create (custom-sort-items found t nil) "*Customize Unsaved*")))) @@ -1360,7 +1360,7 @@ (default-value symbol)))) (push (list symbol 'custom-variable) found))))) (if (not found) - (error "No rogue user options") + (user-error "No rogue user options") (custom-buffer-create (custom-sort-items found t nil) "*Customize Rogue*")))) ;;;###autoload @@ -1378,7 +1378,7 @@ (boundp symbol) (push (list symbol 'custom-variable) found)))) (if (not found ) - (error "No saved user options") + (user-error "No saved user options") (custom-buffer-create (custom-sort-items found t nil) "*Customize Saved*")))) @@ -1410,7 +1410,7 @@ (get symbol 'variable-documentation)))) (push (list symbol 'custom-variable) found))))) (if (not found) - (error "No %s matching %s" + (user-error "No %s matching %s" (if (eq all t) "items" (format "customizable %s" @@ -2244,7 +2244,7 @@ (custom-load-widget widget) (let ((state (widget-get widget :custom-state))) (cond ((memq state '(invalid modified set)) - (error "There are unsaved changes")) + (user-error "There are unsaved changes")) ((eq state 'hidden) (widget-put widget :custom-state 'unknown)) (t @@ -2807,7 +2807,7 @@ (comment (widget-value comment-widget)) val) (cond ((eq state 'hidden) - (error "Cannot set hidden variable")) + (user-error "Cannot set hidden variable")) ((setq val (widget-apply child :validate)) (goto-char (widget-get val :from)) (error "%s" (widget-get val :error))) @@ -2849,7 +2849,7 @@ (comment (widget-value comment-widget)) val) (cond ((eq state 'hidden) - (error "Cannot set hidden variable")) + (user-error "Cannot set hidden variable")) ((setq val (widget-apply child :validate)) (goto-char (widget-get val :from)) (error "Saving %s: %s" symbol (widget-get val :error))) @@ -2907,7 +2907,7 @@ (funcall set symbol (eval (car value))) (error nil))) (t - (error "No saved value for %s" symbol))) + (user-error "No saved value for %s" symbol))) (put symbol 'customized-value nil) (put symbol 'customized-variable-comment nil) (widget-put widget :custom-state 'unknown) @@ -2921,7 +2921,7 @@ (let* ((symbol (widget-value widget))) (if (get symbol 'standard-value) (custom-variable-backup-value widget) - (error "No standard setting known for %S" symbol)) + (user-error "No standard setting known for %S" symbol)) (put symbol 'variable-comment nil) (put symbol 'customized-value nil) (put symbol 'customized-variable-comment nil) @@ -2983,7 +2983,7 @@ (condition-case nil (funcall set symbol (car value)) (error nil))) - (error "No backup value for %s" symbol)) + (user-error "No backup value for %s" symbol)) (put symbol 'customized-value (list (car value))) (put symbol 'variable-comment comment) (put symbol 'customized-variable-comment comment) @@ -3615,7 +3615,7 @@ (comment (get symbol 'saved-face-comment)) (comment-widget (widget-get widget :comment-widget))) (unless (or value comment) - (error "No saved value for this face")) + (user-error "No saved value for this face")) (put symbol 'customized-face nil) (put symbol 'customized-face-comment nil) (custom-push-theme 'theme-face symbol 'user 'set value) @@ -3639,7 +3639,7 @@ (value (get symbol 'face-defface-spec)) (comment-widget (widget-get widget :comment-widget))) (unless value - (error "No standard setting for this face")) + (user-error "No standard setting for this face")) (put symbol 'customized-face nil) (put symbol 'customized-face-comment nil) (custom-push-theme 'theme-face symbol 'user 'reset) @@ -3698,6 +3698,7 @@ :validate (lambda (widget) (unless (facep (widget-value widget)) (widget-put widget + ;; Fix-me: How turn this to user-error? :error (format "Invalid face: %S" (widget-value widget))) widget))) @@ -4245,7 +4246,7 @@ ;; Started with -q, i.e. the file containing ;; Custom settings hasn't been read. Saving ;; settings there would overwrite other settings. - (error "Saving settings from \"emacs -q\" would overwrite existing customizations")) + (user-error "Saving settings from \"emacs -q\" would overwrite existing customizations")) (setq user-init-file default-init-file)) user-init-file)))) @@ -4598,7 +4599,7 @@ (defun Custom-no-edit (pos &optional event) "Invoke button at POS, or refuse to allow editing of Custom buffer." (interactive "@d") - (error "You can't edit this part of the Custom buffer")) + (user-error "You can't edit this part of the Custom buffer")) (defun Custom-newline (pos &optional event) "Invoke button at POS, or refuse to allow editing of Custom buffer." @@ -4606,7 +4607,7 @@ (let ((button (get-char-property pos 'button))) (if button (widget-apply-action button event) - (error "You can't edit this part of the Custom buffer")))) + (user-error "You can't edit this part of the Custom buffer")))) (defun Custom-goto-parent () "Go to the parent group listed at the top of this buffer. @@ -4699,16 +4700,17 @@ (define-obsolete-variable-alias 'custom-mode-hook 'Custom-mode-hook "23.1") (dolist (regexp - '("^No user option defaults have been changed since Emacs " - "^Invalid face:? " - "^No \\(?:customized\\|rogue\\|saved\\) user options" - "^No customizable items matching " - "^There are unset changes" - "^Cannot set hidden variable" - "^No \\(?:saved\\|backup\\) value for " - "^No standard setting known for " - "^No standard setting for this face" - "^Saving settings from \"emacs -q\" would overwrite existing customizations")) + '(;;"^No user option defaults have been changed since Emacs " + "^Invalid face:? " ;; Problems with widget + ;;"^No \\(?:customized\\|rogue\\|saved\\) user options" + "^No customizable items matching " ;; Can't find it + ;;"^There are unset changes" ;; Can't find it + ;;"^Cannot set hidden variable" + ;;"^No \\(?:saved\\|backup\\) value for " + ;;"^No standard setting known for " + ;;"^No standard setting for this face" + ;;"^Saving settings from \"emacs -q\" would overwrite existing customizations" + )) (add-to-list 'debug-ignored-errors regexp)) ;;; The End. Index: lisp/cus-theme.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cus-theme.el,v retrieving revision 1.31 diff -b -u -r1.31 cus-theme.el --- lisp/cus-theme.el 5 Jan 2009 03:18:50 -0000 1.31 +++ lisp/cus-theme.el 28 Nov 2009 01:48:00 -0000 @@ -320,13 +320,13 @@ (cond ((or (string-equal name "") (string-equal name "user") (string-equal name "changed")) - (error "Custom themes cannot be named `%s'" name)) + (user-error "Custom themes cannot be named `%s'" name)) ((string-match " " name) - (error "Custom theme names should not contain spaces")) + (user-error "Custom theme names should not contain spaces")) ((if (file-exists-p filename) (not (y-or-n-p (format "File %s exists. Overwrite? " filename)))) - (error "Aborted"))) + (user-error "Aborted"))) (with-temp-buffer (emacs-lisp-mode) (unless (file-exists-p custom-theme-directory) Index: lisp/dabbrev.el =================================================================== RCS file: /sources/emacs/emacs/lisp/dabbrev.el,v retrieving revision 1.97 diff -b -u -r1.97 dabbrev.el --- lisp/dabbrev.el 25 Nov 2009 05:31:08 -0000 1.97 +++ lisp/dabbrev.el 27 Nov 2009 23:12:18 -0000 @@ -406,7 +406,7 @@ ;; Make an obarray with all expansions (setq my-obarray (make-vector (length completion-list) 0)) (or (> (length my-obarray) 0) - (error "No dynamic expansion for \"%s\" found%s" + (user-error "No dynamic expansion for \"%s\" found%s" abbrev (if dabbrev--check-other-buffers "" " in this-buffer"))) (cond @@ -596,7 +596,7 @@ "Extract the symbol at point to serve as abbreviation." ;; Check for error (if (bobp) - (error "No possible abbreviation preceding point")) + (user-error "No possible abbreviation preceding point")) ;; Return abbrev at point (save-excursion ;; Record the end of the abbreviation. @@ -614,7 +614,7 @@ "\\sw\\|\\s_") nil t) (forward-char 1) - (error "No possible abbreviation preceding point")))) + (user-error "No possible abbreviation preceding point")))) ;; Now find the beginning of that one. (dabbrev--goto-start-of-abbrev) (buffer-substring-no-properties @@ -988,9 +988,10 @@ (cons found-string dabbrev--last-table)) result))))) -(dolist (mess '("^No dynamic expansion for .* found" - "^No further dynamic expansion for .* found$" - "^No possible abbreviation preceding point$")) +(dolist (mess '(;;"^No dynamic expansion for .* found" + ;;"^No further dynamic expansion for .* found$" + ;;"^No possible abbreviation preceding point$" + )) (add-to-list 'debug-ignored-errors mess)) (provide 'dabbrev) Index: lisp/diff-mode.el =================================================================== RCS file: /sources/emacs/emacs/lisp/diff-mode.el,v retrieving revision 1.163 diff -b -u -r1.163 diff-mode.el --- lisp/diff-mode.el 28 Oct 2009 19:30:25 -0000 1.163 +++ lisp/diff-mode.el 28 Nov 2009 01:50:52 -0000 @@ -1355,7 +1355,7 @@ ((< lines 0) (error "End of hunk ambiguously marked")) ((not (y-or-n-p "Try to auto-fix whitespace loss and word-wrap damage? ")) - (error "Abort!")) + (user-error "Abort!")) ((eolp) (insert " ") (forward-line -1) t) (t (insert " ") (delete-region (- (point) 2) (- (point) 1)) t)) (forward-line)))) @@ -1422,7 +1422,7 @@ "End of hunk ambiguously marked" "Hunk seriously messed up"))) ((not (y-or-n-p (concat "Try to auto-fix " (if (eolp) "whitespace loss" "word-wrap damage") "? "))) - (error "Abort!")) + (user-error "Abort!")) ((eolp) (insert " ") (forward-line -1) t) (t (insert " ") (delete-region (- (point) 2) (- (point) 1)) t)))) Index: lisp/dired-aux.el =================================================================== RCS file: /sources/emacs/emacs/lisp/dired-aux.el,v retrieving revision 1.199 diff -b -u -r1.199 dired-aux.el --- lisp/dired-aux.el 25 Nov 2009 17:15:24 -0000 1.199 +++ lisp/dired-aux.el 28 Nov 2009 01:51:13 -0000 @@ -580,7 +580,7 @@ ;; Get confirmation for wildcards that may have been meant ;; to control substitution of a file name or the file name list. (if (cond ((not (or on-each subst)) - (error "You can not combine `*' and `?' substitution marks")) + (user-error "You can not combine `*' and `?' substitution marks")) ((and star (not on-each)) (y-or-n-p "Confirm--do you mean to use `*' as a wildcard? ")) ((and qmark (not subst)) Index: lisp/dired-x.el =================================================================== RCS file: /sources/emacs/emacs/lisp/dired-x.el,v retrieving revision 1.103 diff -b -u -r1.103 dired-x.el --- lisp/dired-x.el 23 Nov 2009 00:32:40 -0000 1.103 +++ lisp/dired-x.el 28 Nov 2009 01:52:00 -0000 @@ -790,7 +790,7 @@ (defun dired-virtual-revert (&optional arg noconfirm) (if (not (y-or-n-p "Cannot revert a Virtual Dired buffer - switch to Real Dired mode? ")) - (error "Cannot revert a Virtual Dired buffer") + (user-error "Cannot revert a Virtual Dired buffer") (setq mode-name "Dired" revert-buffer-function 'dired-revert) (revert-buffer))) Index: lisp/ediff-help.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-help.el,v retrieving revision 1.27 diff -b -u -r1.27 ediff-help.el --- lisp/ediff-help.el 5 Jan 2009 03:18:58 -0000 1.27 +++ lisp/ediff-help.el 27 Nov 2009 23:50:45 -0000 @@ -236,7 +236,7 @@ ((string= cmd "s") (re-search-forward "^`s'")) ((string= cmd "+") (re-search-forward "^`\\+'")) ((string= cmd "=") (re-search-forward "^`='")) - (t (error "Undocumented command! Type `G' in Ediff Control Panel to drop a note to the Ediff maintainer"))) + (t (user-error "Undocumented command! Type `G' in Ediff Control Panel to drop a note to the Ediff maintainer"))) ) ; let case-fold-search )) Index: lisp/ediff-init.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-init.el,v retrieving revision 1.98 diff -b -u -r1.98 ediff-init.el --- lisp/ediff-init.el 22 Nov 2009 03:14:14 -0000 1.98 +++ lisp/ediff-init.el 27 Nov 2009 23:52:03 -0000 @@ -366,7 +366,7 @@ (defsubst ediff-barf-if-not-control-buffer (&optional meta-buf-p) (or (ediff-in-control-buffer-p meta-buf-p) - (error "%S: This command runs in Ediff Control Buffer only!" + (user-error "%S: This command runs in Ediff Control Buffer only!" this-command))) (defgroup ediff-highlighting nil @@ -765,7 +765,7 @@ (funcall op emacs-minor-version minor) t))) (t - (error "%S: Invalid op in ediff-check-version" op))))) + (user-error "%S: Invalid op in ediff-check-version" op))))) ;; ediff-check-version seems to be totally unused anyway. (make-obsolete 'ediff-check-version 'version< "23.1") Index: lisp/ediff-merg.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-merg.el,v retrieving revision 1.45 diff -b -u -r1.45 ediff-merg.el --- lisp/ediff-merg.el 13 Sep 2009 02:14:28 -0000 1.45 +++ lisp/ediff-merg.el 27 Nov 2009 23:52:43 -0000 @@ -282,7 +282,7 @@ Used only for merging jobs." (interactive "P") (if (not ediff-merge-job) - (error "ediff-shrink-window-C can be used only for merging jobs")) + (user-error "ediff-shrink-window-C can be used only for merging jobs")) (cond ((eq arg '-) (setq arg -1)) ((not (numberp arg)) (setq arg nil))) (cond ((null arg) Index: lisp/ediff-mult.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-mult.el,v retrieving revision 1.68 diff -b -u -r1.68 ediff-mult.el --- lisp/ediff-mult.el 22 Nov 2009 03:14:15 -0000 1.68 +++ lisp/ediff-mult.el 28 Nov 2009 01:52:51 -0000 @@ -1170,7 +1170,7 @@ (insert "\n"))) (defun ediff-draw-dir-diffs (diff-list &optional buf-name) - (if (null diff-list) (error "Lost difference info on these directories")) + (if (null diff-list) (user-error "Lost difference info on these directories")) (setq buf-name (or buf-name (ediff-unique-buffer-name "*Ediff File Group Differences" "*"))) @@ -1288,7 +1288,7 @@ "Display differences among the directories involved in session group." (interactive) (if (ediff-one-filegroup-metajob) - (error "This command is inapplicable in the present context")) + (user-error "This command is inapplicable in the present context")) (or (ediff-buffer-live-p ediff-dir-diffs-buffer) (ediff-draw-dir-diffs ediff-dir-difference-list)) (let ((buf ediff-dir-diffs-buffer)) @@ -1369,7 +1369,7 @@ (if (ediff-buffer-live-p ediff-parent-meta-buffer) (ediff-show-meta-buffer ediff-parent-meta-buffer ediff-meta-session-number) - (error "This session group has no parent"))) + (user-error "This session group has no parent"))) ;; argument is ignored @@ -1519,7 +1519,7 @@ (cond (ignore) (unmark (ediff-set-session-status info nil)) ;;; (if (ediff-buffer-live-p session-buf) -;;; (error "Can't hide active session, %s" (buffer-name session-buf))) +;;; (user-error "Can't hide active session, %s" (buffer-name session-buf))) (t (ediff-set-session-status info ?H)))) unmark) @@ -1719,7 +1719,7 @@ (goto-char (point-min)) (display-buffer ediff-tmp-buffer 'not-this-window) )) - (error "The patch buffer wasn't found")))) + (user-error "The patch buffer wasn't found")))) ;; This function executes in meta buffer. It knows where event happened. @@ -1748,7 +1748,7 @@ (progn (ediff-set-session-status info nil) (ediff-update-meta-buffer meta-buf nil session-number)) - (error "Aborted")))) + (user-error "Aborted")))) (ediff-with-current-buffer meta-buf (setq merge-autostore-dir @@ -1846,7 +1846,7 @@ ;; level; see below (setcar (quote ,info) ediff-control-buffer)))) - (error "Aborted"))) + (user-error "Aborted"))) ((ediff-one-filegroup-metajob) ; needs 1 file arg (funcall ediff-session-action-function file1 @@ -1976,7 +1976,7 @@ (setq meta-buf (or meta-buf ediff-meta-buffer)) (cond ((not (bufferp meta-buf)) - (error "This Ediff session is not part of a session group")) + (user-error "This Ediff session is not part of a session group")) ((not (ediff-buffer-live-p meta-buf)) (error "Can't find this session's group panel -- session itself is ok"))) @@ -2046,7 +2046,7 @@ (interactive) (ediff-update-registry) (if (not (ediff-buffer-live-p ediff-registry-buffer)) - (error "No active Ediff sessions or corrupted session registry")) + (user-error "No active Ediff sessions or corrupted session registry")) (let (wind frame) ;; for some reason, point moves in ediff-registry-buffer, so we preserve it ;; explicitly @@ -2174,7 +2174,7 @@ ((ediff-safe-to-quit buf) (bury-buffer)) (t - (error + (user-error "This session group has active sessions---cannot exit"))) (ediff-update-meta-buffer parent-buf nil session-number) (ediff-kill-buffer-carefully dir-diffs-buffer) @@ -2218,7 +2218,7 @@ (or result (unless noerror (ediff-update-registry) - (error "No session info in this line"))))) + (user-error "No session info in this line"))))) (defun ediff-get-meta-overlay-at-pos (point) @@ -2297,7 +2297,7 @@ session-buf beg-marker end-marker) (if (or (file-directory-p file) (string-match "/dev/null" file)) - (error "`%s' is not an ordinary file" (file-name-as-directory file))) + (user-error "`%s' is not an ordinary file" (file-name-as-directory file))) (setq session-buf (ediff-get-session-buffer info) beg-marker (ediff-get-session-objB-name info) end-marker (ediff-get-session-objC-name info)) Index: lisp/ediff-ptch.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-ptch.el,v retrieving revision 1.47 diff -b -u -r1.47 ediff-ptch.el --- lisp/ediff-ptch.el 31 Jan 2009 22:10:29 -0000 1.47 +++ lisp/ediff-ptch.el 28 Nov 2009 00:02:57 -0000 @@ -750,7 +750,7 @@ (select-window aux-wind) (goto-char (point-max)))) (switch-to-buffer-other-window patch-diagnostics) - (error "Patch appears to have failed"))) + (user-error "Patch appears to have failed"))) ;; If black magic is involved, apply patch to a temp copy of the ;; file. Otherwise, apply patch to the orig copy. If patch is applied Index: lisp/ediff-util.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-util.el,v retrieving revision 1.101 diff -b -u -r1.101 ediff-util.el --- lisp/ediff-util.el 25 Nov 2009 17:15:24 -0000 1.101 +++ lisp/ediff-util.el 28 Nov 2009 01:53:11 -0000 @@ -605,7 +605,7 @@ (not (y-or-n-p "Ancestor buffer will not be used. Recompute diffs anyway? "))) - (error "Recomputation of differences canceled")) + (user-error "Recomputation of differences canceled")) (let ((point-A (ediff-with-current-buffer ediff-buffer-A (point))) ;;(point-B (ediff-with-current-buffer ediff-buffer-B (point))) @@ -945,7 +945,7 @@ (interactive) (ediff-barf-if-not-control-buffer) (if ediff-word-mode - (error "No fine differences in this mode")) + (user-error "No fine differences in this mode")) (cond ((eq ediff-auto-refine 'nix) (setq ediff-auto-refine 'on) (ediff-make-fine-diffs ediff-current-difference 'noforce) @@ -965,8 +965,8 @@ (ediff-recenter) (or (ediff-buffer-live-p ediff-ancestor-buffer) (if ediff-merge-with-ancestor-job - (error "Lost connection to ancestor buffer...sorry") - (error "Not merging with ancestor"))) + (user-error "Lost connection to ancestor buffer...sorry") + (user-error "Not merging with ancestor"))) (let (wind) (cond ((setq wind (ediff-get-visible-buffer-window ediff-ancestor-buffer)) (raise-frame (window-frame wind))) @@ -1061,7 +1061,7 @@ (save-window-excursion (select-window (ediff-get-visible-buffer-window buf)) (command-execute toggle-ro-cmd))) - (error "Don't know how to toggle read-only in buffer %S" buf)) + (user-error "Don't know how to toggle read-only in buffer %S" buf)) ;; Check if we made the current buffer updatable, but its file is RO. ;; Signal a warning in this case. @@ -1254,7 +1254,7 @@ (interactive) (ediff-barf-if-not-control-buffer) (or (ediff-window-display-p) - (error "%sEmacs is not running as a window application" + (user-error "%sEmacs is not running as a window application" (if (featurep 'emacs) "" "X"))) (ediff-recenter 'no-rehighlight) ; make sure buffs are displayed in windows (let ((ctl-buf ediff-control-buffer)) @@ -1284,7 +1284,7 @@ (interactive) (let (window-setup-func) (or (ediff-window-display-p) - (error "%sEmacs is not running as a window application" + (user-error "%sEmacs is not running as a window application" (if (featurep 'emacs) "" "X"))) (cond ((eq ediff-window-setup-function 'ediff-setup-windows-multiframe) @@ -1328,7 +1328,7 @@ (if (featurep 'ediff-tbar) (progn (or (ediff-window-display-p) - (error "%sEmacs is not running as a window application" + (user-error "%sEmacs is not running as a window application" (if (featurep 'emacs) "" "X"))) (if (ediff-use-toolbar-p) (ediff-kill-bottom-toolbar)) @@ -1383,7 +1383,7 @@ (interactive) (ediff-barf-if-not-control-buffer) (if (not ediff-merge-with-ancestor-job) - (error "This command makes sense only when merging with an ancestor")) + (user-error "This command makes sense only when merging with an ancestor")) (setq ediff-show-clashes-only (not ediff-show-clashes-only)) (if ediff-show-clashes-only (message "Focus on regions where both buffers differ from the ancestor") @@ -1745,7 +1745,7 @@ (ediff-unselect-and-select-difference n) ) ; let (ediff-visible-region) - (error "At end of the difference list"))) + (user-error "At end of the difference list"))) (defun ediff-previous-difference (&optional arg) "Go to the previous difference. @@ -1794,7 +1794,7 @@ (ediff-unselect-and-select-difference n) ) ; let (ediff-visible-region) - (error "At beginning of the difference list"))) + (user-error "At beginning of the difference list"))) ;; The diff number is as perceived by the user (i.e., 1+ the internal ;; representation) @@ -2113,7 +2113,7 @@ (if (cdr saved-rec) (setq saved-diff (cdr saved-rec)) (if (> ediff-number-of-differences 0) - (error "Nothing saved for diff %d in buffer %S" (1+ n) buf-type) + (user-error "Nothing saved for diff %d in buffer %S" (1+ n) buf-type) (error ediff-NO-DIFFERENCES))) (setq reg-beg (ediff-get-diff-posn buf-type 'beg n ediff-control-buffer)) @@ -3249,7 +3249,7 @@ (error (beep) (message "Couldn't save %s" buffer-file-name))) - (error "Buffer is out of sync for file %s" buffer-file-name)) + (user-error "Buffer is out of sync for file %s" buffer-file-name)) ;; If buffer is not obsolete and is not modified, do nothing nil) ;; If buffer is obsolete, offer to revert @@ -3262,7 +3262,7 @@ (if file-magic (erase-buffer)) (revert-buffer t t)) - (error "Buffer out of sync for file %s" buffer-file-name)))) + (user-error "Buffer out of sync for file %s" buffer-file-name)))) ;; if there is another buffer visiting the file of the merge buffer, offer to ;; save and delete the buffer; else bark @@ -3317,7 +3317,7 @@ ediff-custom-diff-buffer) ((ediff-buffer-live-p ediff-diff-buffer) ediff-diff-buffer) - (t (error "Output from `diff' not found")))) + (t (user-error "Output from `diff' not found")))) ) (let ((window-min-height 2)) (save-buffer)))) Index: lisp/ediff-wind.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff-wind.el,v retrieving revision 1.67 diff -b -u -r1.67 ediff-wind.el --- lisp/ediff-wind.el 16 Apr 2009 03:50:33 -0000 1.67 +++ lisp/ediff-wind.el 28 Nov 2009 01:29:42 -0000 @@ -1113,7 +1113,7 @@ This function modifies only the left margin and the width of the display. It assumes that it is called from within the control buffer." (if (not (fboundp 'ediff-display-pixel-width)) - (error "Can't determine display width")) + (user-error "Can't determine display width")) (let* ((frame-A (window-frame ediff-window-A)) (frame-A-params (frame-parameters frame-A)) (cw (ediff-frame-char-width frame-A)) Index: lisp/ediff.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ediff.el,v retrieving revision 1.111 diff -b -u -r1.111 ediff.el --- lisp/ediff.el 22 Nov 2009 03:14:15 -0000 1.111 +++ lisp/ediff.el 28 Nov 2009 01:54:20 -0000 @@ -288,9 +288,9 @@ (file-magic (ediff-filename-magic-p file)) (temp-file-name-prefix (file-name-nondirectory file))) (cond ((not (file-readable-p file)) - (error "File `%s' does not exist or is not readable" file)) + (user-error "File `%s' does not exist or is not readable" file)) ((file-directory-p file) - (error "File `%s' is a directory" file))) + (user-error "File `%s' is a directory" file))) ;; some of the commands, below, require full file name (setq file (expand-file-name file)) @@ -372,7 +372,7 @@ (or (buffer-modified-p) (not (verify-visited-file-modtime (current-buffer)))))) - (error "Nothing to revert")) + (user-error "Nothing to revert")) (let* ((auto-save-p (and (recent-auto-save-p) buffer-auto-save-file-name (file-readable-p buffer-auto-save-file-name) @@ -476,13 +476,13 @@ (buffer-file-name (get-buffer buf-B)))) file-A file-B file-C) (if (not (ediff-buffer-live-p buf-A)) - (error "Buffer %S doesn't exist" buf-A)) + (user-error "Buffer %S doesn't exist" buf-A)) (if (not (ediff-buffer-live-p buf-B)) - (error "Buffer %S doesn't exist" buf-B)) + (user-error "Buffer %S doesn't exist" buf-B)) (let ((ediff-job-name job-name)) (if (and ediff-3way-comparison-job (not buf-C-is-alive)) - (error "Buffer %S doesn't exist" buf-C))) + (user-error "Buffer %S doesn't exist" buf-C))) (if (stringp buf-A-file-name) (setq buf-A-file-name (file-name-nondirectory buf-A-file-name))) (if (stringp buf-B-file-name) @@ -773,13 +773,13 @@ (setq dir3 (if (file-directory-p dir3) dir3 (file-name-directory dir3)))) (cond ((string= dir1 dir2) - (error "Directories A and B are the same: %s" dir1)) + (user-error "Directories A and B are the same: %s" dir1)) ((and (eq jobname 'ediff-directories3) (string= dir1 dir3)) - (error "Directories A and C are the same: %s" dir1)) + (user-error "Directories A and C are the same: %s" dir1)) ((and (eq jobname 'ediff-directories3) (string= dir2 dir3)) - (error "Directories B and C are the same: %s" dir1))) + (user-error "Directories B and C are the same: %s" dir1))) (if merge-autostore-dir (or (stringp merge-autostore-dir) @@ -805,15 +805,15 @@ (cond ((and (stringp dir1) (string= merge-autostore-dir dir1)) (or (y-or-n-p "Directory for saving merged files = Directory A. Sure? ") - (error "Directory merge aborted"))) + (user-error "Directory merge aborted"))) ((and (stringp dir2) (string= merge-autostore-dir dir2)) (or (y-or-n-p "Directory for saving merged files = Directory B. Sure? ") - (error "Directory merge aborted"))) + (user-error "Directory merge aborted"))) ((and (stringp dir3) (string= merge-autostore-dir dir3)) (or (y-or-n-p "Directory for saving merged files = Ancestor Directory. Sure? ") - (error "Directory merge aborted"))))) + (user-error "Directory merge aborted"))))) (setq dir-diff-struct (ediff-intersect-directories jobname @@ -866,7 +866,7 @@ (string= merge-autostore-dir dir1)) (or (y-or-n-p "Directory for saving merged file = directory A. Sure? ") - (error "Merge of directory revisions aborted"))) + (user-error "Merge of directory revisions aborted"))) (setq file-list (ediff-get-directory-files-under-revision @@ -967,9 +967,9 @@ (ediff-other-buffer bf)) t)))) (if (not (ediff-buffer-live-p buffer-A)) - (error "Buffer %S doesn't exist" buffer-A)) + (user-error "Buffer %S doesn't exist" buffer-A)) (if (not (ediff-buffer-live-p buffer-B)) - (error "Buffer %S doesn't exist" buffer-B)) + (user-error "Buffer %S doesn't exist" buffer-B)) (let ((buffer-A @@ -1008,9 +1008,9 @@ (ediff-other-buffer bf)) t)))) (if (not (ediff-buffer-live-p buffer-A)) - (error "Buffer %S doesn't exist" buffer-A)) + (user-error "Buffer %S doesn't exist" buffer-A)) (if (not (ediff-buffer-live-p buffer-B)) - (error "Buffer %S doesn't exist" buffer-B)) + (user-error "Buffer %S doesn't exist" buffer-B)) (let ((buffer-A (ediff-clone-buffer-for-region-comparison buffer-A "-Region.A-")) @@ -1442,7 +1442,7 @@ (message "") ; kill the message from `locate-library' (require ediff-version-control-package)) (or silent - (error "Version control package %S.el not found. Use vc.el instead" + (user-error "Version control package %S.el not found. Use vc.el instead" ediff-version-control-package))))) @@ -1488,52 +1488,52 @@ (set-window-buffer ctl-window ctl-buf))))))) -(dolist (mess '("^Errors in diff output. Diff output is in " - "^Hmm... I don't see an Ediff command around here...$" - "^Undocumented command! Type `G' in Ediff Control Panel to drop a note to the Ediff maintainer$" - ": This command runs in Ediff Control Buffer only!$" - ": Invalid op in ediff-check-version$" - "^ediff-shrink-window-C can be used only for merging jobs$" - "^Lost difference info on these directories$" - "^This command is inapplicable in the present context$" - "^This session group has no parent$" - "^Can't hide active session, $" - "^Ediff: something wrong--no multiple diffs buffer$" - "^Can't make context diff for Session $" - "^The patch buffer wasn't found$" - "^Aborted$" - "^This Ediff session is not part of a session group$" - "^No active Ediff sessions or corrupted session registry$" - "^No session info in this line$" - "^`.*' is not an ordinary file$" - "^Patch appears to have failed$" - "^Recomputation of differences cancelled$" - "^No fine differences in this mode$" - "^Lost connection to ancestor buffer...sorry$" - "^Not merging with ancestor$" - "^Don't know how to toggle read-only in buffer " - "Emacs is not running as a window application$" - "^This command makes sense only when merging with an ancestor$" - "^At end of the difference list$" - "^At beginning of the difference list$" - "^Nothing saved for diff .* in buffer " - "^Buffer is out of sync for file " - "^Buffer out of sync for file " - "^Output from `diff' not found$" - "^You forgot to specify a region in buffer " - "^All right. Make up your mind and come back...$" - "^Current buffer is not visiting any file$" - "^Failed to retrieve revision: $" - "^Can't determine display width.$" - "^File `.*' does not exist or is not readable$" - "^File `.*' is a directory$" - "^Buffer .* doesn't exist$" - "^Directories . and . are the same: " - "^Directory merge aborted$" - "^Merge of directory revisions aborted$" - "^Buffer .* doesn't exist$" - "^There is no file to merge$" - "^Version control package .*.el not found. Use vc.el instead$")) +(dolist (mess '(;;"^Errors in diff output. Diff output is in " + ;;"^Hmm... I don't see an Ediff command around here...$" + ;;"^Undocumented command! Type `G' in Ediff Control Panel to drop a note to the Ediff maintainer$" + ;;": This command runs in Ediff Control Buffer only!$" + ;;": Invalid op in ediff-check-version$" + ;;"^ediff-shrink-window-C can be used only for merging jobs$" + ;;"^Lost difference info on these directories$" + ;;"^This command is inapplicable in the present context$" + ;;"^This session group has no parent$" + ;;"^Can't hide active session, $" + ;;"^Ediff: something wrong--no multiple diffs buffer$" + ;;"^Can't make context diff for Session $" + ;;"^The patch buffer wasn't found$" + ;;"^Aborted$" + ;;"^This Ediff session is not part of a session group$" + ;;"^No active Ediff sessions or corrupted session registry$" + ;;"^No session info in this line$" + ;;"^`.*' is not an ordinary file$" + ;;"^Patch appears to have failed$" + ;;"^Recomputation of differences cancelled$" + ;;"^No fine differences in this mode$" + ;;"^Lost connection to ancestor buffer...sorry$" + ;;"^Not merging with ancestor$" + ;;"^Don't know how to toggle read-only in buffer " + ;;"Emacs is not running as a window application$" + ;;"^This command makes sense only when merging with an ancestor$" + ;;"^At end of the difference list$" + ;;"^At beginning of the difference list$" + ;;"^Nothing saved for diff .* in buffer " + ;;"^Buffer is out of sync for file " + ;;"^Buffer out of sync for file " + ;;"^Output from `diff' not found$" + ;;"^You forgot to specify a region in buffer " + ;;"^All right. Make up your mind and come back...$" + ;;"^Current buffer is not visiting any file$" + ;;"^Failed to retrieve revision: $" + ;;"^Can't determine display width.$" + ;;"^File `.*' does not exist or is not readable$" + ;;"^File `.*' is a directory$" + ;;"^Buffer .* doesn't exist$" + ;;"^Directories . and . are the same: " + ;;"^Directory merge aborted$" + ;;"^Merge of directory revisions aborted$" + ;;"^Buffer .* doesn't exist$" + ;;"^There is no file to merge$" + ;;"^Version control package .*.el not found. Use vc.el instead$")) (add-to-list 'debug-ignored-errors mess)) Index: lisp/edmacro.el =================================================================== RCS file: /sources/emacs/emacs/lisp/edmacro.el,v retrieving revision 1.54 diff -b -u -r1.54 edmacro.el --- lisp/edmacro.el 26 May 2009 20:19:34 -0000 1.54 +++ lisp/edmacro.el 28 Nov 2009 01:56:28 -0000 @@ -119,7 +119,7 @@ ((eq cmd 'execute-extended-command) (setq cmd (read-command "Name of keyboard macro to edit: ")) (if (string-equal cmd "") - (error "No command name given")) + (user-error "No command name given")) (setq keys nil) (setq mac (symbol-function cmd))) ((memq cmd '(view-lossage electric-view-lossage)) @@ -127,7 +127,7 @@ (setq keys nil) (setq cmd 'last-kbd-macro)) ((null cmd) - (error "Key sequence %s is not defined" (key-description keys))) + (user-error "Key sequence %s is not defined" (key-description keys))) ((symbolp cmd) (setq mac (symbol-function cmd))) (t @@ -138,7 +138,7 @@ mac-counter (nth 1 kmacro) mac-format (nth 2 kmacro))) (unless (arrayp mac) - (error "Key sequence %s is not a keyboard macro" + (user-error "Key sequence %s is not a keyboard macro" (key-description keys))) (message "Formatting keyboard macro...") (let* ((oldbuf (current-buffer)) @@ -226,7 +226,7 @@ (defun edmacro-finish-edit () (interactive) (unless (eq major-mode 'edmacro-mode) - (error + (user-error "This command is valid only in buffers created by `edit-kbd-macro'")) (run-hooks 'edmacro-finish-hook) (let ((cmd nil) (keys nil) (no-keys nil) @@ -238,7 +238,7 @@ t) ((looking-at "Command:[ \t]*\\([^ \t\n]*\\)[ \t]*$") (when edmacro-store-hook - (error "\"Command\" line not allowed in this context")) + (user-error "\"Command\" line not allowed in this context")) (let ((str (buffer-substring (match-beginning 1) (match-end 1)))) (unless (equal str "") @@ -253,7 +253,7 @@ t) ((looking-at "Key:\\(.*\\)$") (when edmacro-store-hook - (error "\"Key\" line not allowed in this context")) + (user-error "\"Key\" line not allowed in this context")) (let ((key (edmacro-parse-keys (buffer-substring (match-beginning 1) (match-end 1))))) @@ -275,7 +275,7 @@ t) ((looking-at "Counter:[ \t]*\\([^ \t\n]*\\)[ \t]*$") (when edmacro-store-hook - (error "\"Counter\" line not allowed in this context")) + (user-error "\"Counter\" line not allowed in this context")) (let ((str (buffer-substring (match-beginning 1) (match-end 1)))) (unless (equal str "") @@ -283,7 +283,7 @@ t) ((looking-at "Format:[ \t]*\"\\([^\n]*\\)\"[ \t]*$") (when edmacro-store-hook - (error "\"Format\" line not allowed in this context")) + (user-error "\"Format\" line not allowed in this context")) (let ((str (buffer-substring (match-beginning 1) (match-end 1)))) (unless (equal str "") @@ -303,7 +303,7 @@ (store-hook edmacro-store-hook) (finish-hook edmacro-finish-hook)) (unless (or cmd keys store-hook (equal str "")) - (error "No command name or keys specified")) + (user-error "No command name or keys specified")) (when modp (when (buffer-name obuf) (set-buffer obuf)) Index: lisp/epa-mail.el =================================================================== RCS file: /sources/emacs/emacs/lisp/epa-mail.el,v retrieving revision 1.6 diff -b -u -r1.6 epa-mail.el --- lisp/epa-mail.el 5 Jan 2009 03:19:05 -0000 1.6 +++ lisp/epa-mail.el 28 Nov 2009 02:02:28 -0000 @@ -154,7 +154,7 @@ (format "No public key for %s; skip it? " recipient))) - (error "No public key for %s" recipient)) + (user-error "No public key for %s" recipient)) recipient-key) recipients))) (setq sign (if verbose (y-or-n-p "Sign? "))) Index: lisp/ffap.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ffap.el,v retrieving revision 1.88 diff -b -u -r1.88 ffap.el --- lisp/ffap.el 25 Nov 2009 17:11:35 -0000 1.88 +++ lisp/ffap.el 28 Nov 2009 02:03:39 -0000 @@ -1821,7 +1821,7 @@ (y-or-n-p "Directory does not exist, create it? ")) (make-directory filename) (funcall ffap-directory-finder filename)) - ((error "No such file or directory `%s'" filename))))) + ((user-error "No such file or directory `%s'" filename))))) (defun dired-at-point-prompter (&optional guess) ;; Does guess and prompt step for find-file-at-point. Index: lisp/files.el =================================================================== RCS file: /sources/emacs/emacs/lisp/files.el,v retrieving revision 1.1102 diff -b -u -r1.1102 files.el --- lisp/files.el 25 Nov 2009 17:11:35 -0000 1.1102 +++ lisp/files.el 28 Nov 2009 02:04:58 -0000 @@ -1705,7 +1705,7 @@ (format "File %s is large (%dMB), really %s? " (file-name-nondirectory filename) (/ size 1048576) op-type)))) - (error "Aborted"))) + (user-error "Aborted"))) (defun find-file-noselect (filename &optional nowarn rawfile wildcards) "Read file FILENAME into a buffer and return the buffer. @@ -1853,7 +1853,7 @@ Do you want to discard your changes, and visit the file normally now? "))) (find-file-noselect-1 buf filename nowarn rawfile truename number) - (error (if rawfile "File already visited non-literally" + (user-error (if rawfile "File already visited non-literally" "File already visited literally")))) (if (y-or-n-p (format @@ -3480,7 +3480,7 @@ (not no-query) (not (y-or-n-p (format "A buffer is visiting %s; proceed? " filename))) - (error "Aborted"))) + (user-error "Aborted"))) (or (equal filename buffer-file-name) (progn (and filename (lock-buffer filename)) @@ -3591,7 +3591,7 @@ (and confirm (file-exists-p filename) (or (y-or-n-p (format "File `%s' exists; overwrite? " filename)) - (error "Canceled"))) + (user-error "Canceled"))) (set-visited-file-name filename (not confirm)))) (set-buffer-modified-p t) ;; Make buffer writable if file is writable. @@ -4193,7 +4193,7 @@ (error "%s is a directory" filename) (unless (y-or-n-p (format "File `%s' exists; overwrite? " filename)) - (error "Canceled"))) + (user-error "Canceled"))) ;; Signal an error if the specified name refers to a ;; non-existing directory. (let ((dir (file-name-directory filename))) @@ -4207,7 +4207,7 @@ (yes-or-no-p (format "%s has changed since visited or saved. Save anyway? " (file-name-nondirectory buffer-file-name))) - (error "Save not confirmed")) + (user-error "Save not confirmed")) (save-restriction (widen) (save-excursion @@ -4970,7 +4970,7 @@ (insert-file-contents file-name nil) (set-buffer-file-coding-system coding-system)) (after-find-file nil nil t)) - (t (error "Recover-file cancelled"))))) + (t (user-error "Recover-file cancelled"))))) (defun recover-session () "Recover auto save files from a previous Emacs session. Index: lisp/frame.el =================================================================== RCS file: /sources/emacs/emacs/lisp/frame.el,v retrieving revision 1.302 diff -b -u -r1.302 frame.el --- lisp/frame.el 10 Oct 2009 23:50:14 -0000 1.302 +++ lisp/frame.el 28 Nov 2009 02:06:54 -0000 @@ -687,7 +687,7 @@ (not (y-or-n-p (if (cdr frames) (format "Delete %s frames? " (length frames)) (format "Delete %s ? " (car frames)))))) - (error "Abort!") + (user-error "Abort!") (mapc 'delete-frame frames) (x-close-connection display)))) Index: lisp/imenu.el =================================================================== RCS file: /sources/emacs/emacs/lisp/imenu.el,v retrieving revision 1.132 diff -b -u -r1.132 imenu.el --- lisp/imenu.el 26 Aug 2009 03:07:26 -0000 1.132 +++ lisp/imenu.el 27 Nov 2009 23:27:43 -0000 @@ -587,7 +587,7 @@ (funcall imenu-create-index-function)))) (imenu--truncate-items imenu--index-alist))) (or imenu--index-alist noerror - (error "No items suitable for an index found in this buffer")) + (user-error "No items suitable for an index found in this buffer")) (or imenu--index-alist (setq imenu--index-alist (list nil))) ;; Add a rescan option to the index. @@ -703,7 +703,7 @@ ((and imenu-generic-expression) (imenu--generic-function imenu-generic-expression)) (t - (error "This buffer cannot use `imenu-default-create-index-function'")))) + (user-error "This buffer cannot use `imenu-default-create-index-function'")))) ;;; ;;; Generic index gathering function. @@ -968,7 +968,7 @@ `(menu-item ,name ,(make-sparse-keymap "Imenu"))) (use-local-map newmap) (add-hook 'menu-bar-update-hook 'imenu-update-menubar)) - (error "The mode `%s' does not support Imenu" + (user-error "The mode `%s' does not support Imenu" (format-mode-line mode-name)))) ;;;###autoload @@ -1056,9 +1056,10 @@ (run-hooks 'imenu-after-jump-hook))) (dolist (mess - '("^No items suitable for an index found in this buffer$" - "^This buffer cannot use `imenu-default-create-index-function'$" - "^The mode `.*' does not support Imenu$")) + '(;;"^No items suitable for an index found in this buffer$" + ;;"^This buffer cannot use `imenu-default-create-index-function'$" + ;;"^The mode `.*' does not support Imenu$" + )) (add-to-list 'debug-ignored-errors mess)) (provide 'imenu) Index: lisp/info.el =================================================================== RCS file: /sources/emacs/emacs/lisp/info.el,v retrieving revision 1.570 diff -b -u -r1.570 info.el --- lisp/info.el 11 Nov 2009 05:49:13 -0000 1.570 +++ lisp/info.el 27 Nov 2009 22:55:44 -0000 @@ -1043,7 +1043,7 @@ (throw 'foo t)) ;; No such anchor in tag table or node in tag table or file - (error "No such node or anchor: %s" nodename)) + (user-error "No such node or anchor: %s" nodename)) (Info-select-node) (goto-char (point-min)) @@ -1949,7 +1949,7 @@ (concat name ":" (Info-following-node-name-re)) bound t) (match-string-no-properties 1)) ((not (eq errorname t)) - (error "Node has no %s" + (user-error "Node has no %s" (capitalize (or errorname name))))))))) (defun Info-following-node-name-re (&optional allowedchars) @@ -2019,7 +2019,7 @@ "Go back in the history to the last node visited." (interactive) (or Info-history - (error "This is the first Info node you looked at")) + (user-error "This is the first Info node you looked at")) (let ((history-forward (cons (list Info-current-file Info-current-node (point)) Info-history-forward)) @@ -2039,7 +2039,7 @@ "Go forward in the history of visited nodes." (interactive) (or Info-history-forward - (error "This is the last Info node you looked at")) + (user-error "This is the last Info node you looked at")) (let ((history-forward (cdr Info-history-forward)) filename nodename opoint) (setq filename (car (car Info-history-forward))) @@ -2328,7 +2328,7 @@ completions nil t))) (list (if (equal input "") default input) current-prefix-arg)) - (error "No cross-references in this node")))) + (user-error "No cross-references in this node")))) (unless footnotename (error "No reference was specified")) @@ -2359,7 +2359,7 @@ (abs (- prev-ref (point)))) next-ref prev-ref)) ((or next-ref prev-ref)) - ((error "No cross-reference named %s" footnotename)))) + ((user-error "No cross-reference named %s" footnotename)))) (setq target (Info-extract-menu-node-name t)))) (while (setq i (string-match "[ \t\n]+" target i)) (setq target (concat (substring target 0 i) " " @@ -2503,7 +2503,7 @@ (save-excursion (goto-char (point-min)) (if (not (search-forward "\n* menu:" nil t)) - (error "No menu in this node")) + (user-error "No menu in this node")) (setq beg (point)) (and (< (point) p) (save-excursion @@ -2542,10 +2542,10 @@ (let ((case-fold-search t)) (goto-char (point-min)) (or (search-forward "\n* menu:" nil t) - (error "No menu in this node")) + (user-error "No menu in this node")) (or (re-search-forward (concat "\n\\* +" menu-item ":") nil t) (re-search-forward (concat "\n\\* +" menu-item) nil t) - (error "No such item in menu")) + (user-error "No such item in menu")) (beginning-of-line) (forward-char 2) (Info-extract-menu-node-name nil (Info-index-node)))))) @@ -2561,7 +2561,7 @@ (match-beginning 0)))) (goto-char (point-min)) (or (search-forward "\n* menu:" bound t) - (error "No menu in this node")) + (user-error "No menu in this node")) (if count (or (search-forward "\n* " bound t count) (error "Too few items in menu")) @@ -2630,7 +2630,7 @@ (setq success (Info-forward-node t nil no-error)) (or success (Info-goto-node old-node)))))) (no-error nil) - (t (error "No pointer forward from this node"))))) + (t (user-error "No pointer forward from this node"))))) (defun Info-backward-node () "Go backward one node, considering all nodes as forming one sequence." @@ -2639,7 +2639,7 @@ (upnode (Info-extract-pointer "up" t)) (case-fold-search t)) (cond ((and upnode (string-match "(" upnode)) - (error "First node in file")) + (user-error "First node in file")) ((and upnode (or (null prevnode) ;; Use string-equal, not equal, ;; to ignore text properties. @@ -2655,7 +2655,7 @@ (save-excursion (search-forward "\n* Menu:" nil t))) (Info-goto-node (Info-extract-menu-counting nil))))) (t - (error "No pointer backward from this node"))))) + (user-error "No pointer backward from this node"))))) (defun Info-exit () "Exit Info by selecting some other buffer." @@ -2676,7 +2676,7 @@ (and (search-forward "\n* " nil t) (Info-extract-menu-node-name))))) (if node (Info-goto-node node) - (error "No more items in menu")))) + (user-error "No more items in menu")))) (defun Info-last-menu-item () "Go to the node of the previous menu item." @@ -2689,7 +2689,7 @@ (and (search-backward "\n* menu:" nil t) (point))))) (or (and beg (search-backward "\n* " beg t)) - (error "No previous items in menu"))) + (user-error "No previous items in menu"))) (Info-goto-node (save-excursion (goto-char (match-end 0)) (Info-extract-menu-node-name))))) @@ -2712,7 +2712,7 @@ (let (Info-history) (Info-next-preorder))) (t - (error "No more nodes")))) + (user-error "No more nodes")))) (defun Info-last-preorder () "Go to the last node, popping up a level if there is none." @@ -2745,7 +2745,7 @@ (let ((case-fold-search t)) (or (search-forward "\n* Menu:" nil t) (goto-char (point-max))))) - (t (error "No previous nodes")))) + (t (user-error "No previous nodes")))) (defun Info-scroll-up () "Scroll one screenful forward in Info, considering all nodes as one sequence. @@ -2837,11 +2837,11 @@ (or (re-search-forward pat nil t) (progn (goto-char old-pt) - (error "No cross references in this node"))))) + (user-error "No cross references in this node"))))) (goto-char (or (match-beginning 1) (match-beginning 0))) (if (looking-at "\\* Menu:") (if recur - (error "No cross references in this node") + (user-error "No cross references in this node") (Info-next-reference t)) (if (looking-at "^\\* ") (forward-char 2))))) @@ -2858,11 +2858,11 @@ (or (re-search-backward pat nil t) (progn (goto-char old-pt) - (error "No cross references in this node"))))) + (user-error "No cross references in this node"))))) (goto-char (or (match-beginning 1) (match-beginning 0))) (if (looking-at "\\* Menu:") (if recur - (error "No cross references in this node") + (user-error "No cross references in this node") (Info-prev-reference t)) (if (looking-at "^\\* ") (forward-char 2))))) @@ -3033,7 +3033,7 @@ (or matches (progn (Info-goto-node orignode) - (error "No `%s' in index" topic))) + (user-error "No `%s' in index" topic))) ;; Here it is a feature that assoc is case-sensitive. (while (setq found (assoc topic matches)) (setq exact (cons found exact) @@ -3046,7 +3046,7 @@ "Go to the next matching index item from the last \\\\[Info-index] command." (interactive "p") (or Info-index-alternatives - (error "No previous `i' command")) + (user-error "No previous `i' command")) (while (< num 0) (setq num (+ num (length Info-index-alternatives)))) (while (> num 0) @@ -3510,7 +3510,7 @@ ;; Don't raise an error when mouse-1 is bound to this - it's ;; often used to simply select the window or frame. (eq 'mouse-1 (event-basic-type last-input-event))) - (error "Point neither on reference nor in menu item description"))) + (user-error "Point neither on reference nor in menu item description"))) ;; Common subroutine. (defun Info-try-follow-nearest-node (&optional fork) @@ -3750,7 +3750,7 @@ With a zero prefix arg, put the name inside a function call to `info'." (interactive "P") (unless Info-current-node - (error "No current Info node")) + (user-error "No current Info node")) (let ((node (if (stringp Info-current-file) (concat "(" (file-name-nondirectory Info-current-file) ") " Info-current-node)))) @@ -4719,23 +4719,23 @@ (erase-buffer)) (Info-speedbar-hierarchy-buttons nil 0)) -(dolist (mess '("^First node in file$" - "^No `.*' in index$" - "^No cross-reference named" - "^No cross.references in this node$" - "^No current Info node$" - "^No menu in this node$" - "^No more items in menu$" - "^No more nodes$" - "^No pointer \\(?:forward\\|backward\\) from this node$" - "^No previous `i' command$" - "^No previous items in menu$" - "^No previous nodes$" - "^No such item in menu$" - "^No such node or anchor" - "^Node has no" - "^Point neither on reference nor in menu item description$" - "^This is the \\(?:first\\|last\\) Info node you looked at$" +(dolist (mess '(;;"^First node in file$" + ;;"^No `.*' in index$" + ;;"^No cross-reference named" + ;;"^No cross.references in this node$" + ;;"^No current Info node$" + ;;"^No menu in this node$" + ;;"^No more items in menu$" + ;;"^No more nodes$" + ;;"^No pointer \\(?:forward\\|backward\\) from this node$" + ;;"^No previous `i' command$" + ;;"^No previous items in menu$" + ;;"^No previous nodes$" + ;;"^No such item in menu$" + ;;"^No such node or anchor" + ;;"^Node has no" + ;;"^Point neither on reference nor in menu item description$" + ;;"^This is the \\(?:first\\|last\\) Info node you looked at$" search-failed)) (add-to-list 'debug-ignored-errors mess)) Index: lisp/man.el =================================================================== RCS file: /sources/emacs/emacs/lisp/man.el,v retrieving revision 1.192 diff -b -u -r1.192 man.el --- lisp/man.el 27 Nov 2009 04:08:07 -0000 1.192 +++ lisp/man.el 27 Nov 2009 23:28:37 -0000 @@ -1195,7 +1195,7 @@ (if (not Man-page-list) (let ((args Man-arguments)) (kill-buffer (current-buffer)) - (error "Can't find the %s manpage" args))) + (user-error "Can't find the %s manpage" args))) (set-buffer-modified-p nil) )) @@ -1552,7 +1552,7 @@ (when Man-page-list (if (or (< page 1) (> page (length Man-page-list))) - (error "No manpage %d found" page)) + (user-error "No manpage %d found" page)) (let* ((page-range (nth (1- page) Man-page-list)) (page-start (car page-range)) (page-end (car (cdr page-range)))) @@ -1605,8 +1605,8 @@ ;; Init the man package variables, if not already done. (Man-init-defvars) -(add-to-list 'debug-ignored-errors "^No manpage [0-9]* found$") -(add-to-list 'debug-ignored-errors "^Can't find the .* manpage$") +;;(add-to-list 'debug-ignored-errors "^No manpage [0-9]* found$") +;;(add-to-list 'debug-ignored-errors "^Can't find the .* manpage$") (provide 'man) Index: lisp/mouse.el =================================================================== RCS file: /sources/emacs/emacs/lisp/mouse.el,v retrieving revision 1.363 diff -b -u -r1.363 mouse.el --- lisp/mouse.el 13 Nov 2009 22:19:53 -0000 1.363 +++ lisp/mouse.el 28 Nov 2009 00:58:30 -0000 @@ -294,7 +294,7 @@ (let ((w (posn-window (event-start event)))) (and (window-minibuffer-p w) (not (minibuffer-window-active-p w)) - (error "Minibuffer window is not active"))) + (user-error "Minibuffer window is not active"))) ;; Give temporary modes such as isearch a chance to turn off. (run-hooks 'mouse-leave-buffer-hook)) Index: lisp/ses.el =================================================================== RCS file: /sources/emacs/emacs/lisp/ses.el,v retrieving revision 1.41 diff -b -u -r1.41 ses.el --- lisp/ses.el 28 Aug 2009 17:02:56 -0000 1.41 +++ lisp/ses.el 28 Nov 2009 00:32:55 -0000 @@ -2468,7 +2468,7 @@ (or (eq last-command 'yank) ;;Use noreturn here just to avoid a "poor-coverage" warning in its ;;macro definition. - (noreturn (error "Previous command was not a yank"))) + (noreturn (user-error "Previous command was not a yank"))) (undo) (ses-set-curcell) (yank (1+ (or arg 1))) Index: lisp/simple.el =================================================================== RCS file: /sources/emacs/emacs/lisp/simple.el,v retrieving revision 1.1033 diff -b -u -r1.1033 simple.el --- lisp/simple.el 19 Nov 2009 20:58:45 -0000 1.1033 +++ lisp/simple.el 28 Nov 2009 01:07:11 -0000 @@ -1271,7 +1271,7 @@ (list (if (string= regexp "") (if minibuffer-history-search-history (car minibuffer-history-search-history) - (error "No previous history search regexp")) + (user-error "No previous history search regexp")) regexp) (prefix-numeric-value current-prefix-arg)))) (unless (zerop n) @@ -1297,7 +1297,7 @@ (setq prevpos pos) (setq pos (min (max 1 (+ pos (if (< n 0) -1 1))) (length history))) (when (= pos prevpos) - (error (if (= pos 1) + (user-error (if (= pos 1) "No later matching history item" "No earlier matching history item"))) (setq match-string @@ -1342,7 +1342,7 @@ (list (if (string= regexp "") (if minibuffer-history-search-history (car minibuffer-history-search-history) - (error "No previous history search regexp")) + (user-error "No previous history search regexp")) regexp) (prefix-numeric-value current-prefix-arg)))) (previous-matching-history-element regexp (- n))) @@ -1402,10 +1402,10 @@ (minibuffer-contents-no-properties))) (if (< nabs minimum) (if minibuffer-default - (error "End of defaults; no next item") - (error "End of history; no default available"))) + (user-error "End of defaults; no next item") + (user-error "End of history; no default available"))) (if (> nabs (length (symbol-value minibuffer-history-variable))) - (error "Beginning of history; no preceding item")) + (user-error "Beginning of history; no preceding item")) (unless (memq last-command '(next-history-element previous-history-element)) (let ((prompt-end (minibuffer-prompt-end))) @@ -1751,7 +1751,7 @@ Call `undo-start' to get ready to undo recent changes, then call `undo-more' one or more times to undo them." (or (listp pending-undo-list) - (error (concat "No further undo information" + (user-error (concat "No further undo information" (and undo-in-region " for region")))) (let ((undo-in-progress t)) ;; Note: The following, while pulling elements off @@ -1778,7 +1778,7 @@ that apply to text between BEG and END are used; other undo elements are ignored. If BEG and END are nil, all undo elements are used." (if (eq buffer-undo-list t) - (error "No undo information in this buffer")) + (user-error "No undo information in this buffer")) (setq pending-undo-list (if (and beg end (not (= beg end))) (undo-make-selective-list (min beg end) (max beg end)) @@ -3115,7 +3115,7 @@ doc string for `insert-for-yank-1', which see." (interactive "*p") (if (not (eq last-command 'yank)) - (error "Previous command was not a yank")) + (user-error "Previous command was not a yank")) (setq this-command 'yank) (unless arg (setq arg 1)) (let ((inhibit-read-only t) Index: lisp/smerge-mode.el =================================================================== RCS file: /sources/emacs/emacs/lisp/smerge-mode.el,v retrieving revision 1.79 diff -b -u -r1.79 smerge-mode.el --- lisp/smerge-mode.el 4 Oct 2009 02:11:58 -0000 1.79 +++ lisp/smerge-mode.el 27 Nov 2009 23:38:05 -0000 @@ -343,12 +343,12 @@ )))) (defvar smerge-resolve-function - (lambda () (error "Don't know how to resolve")) + (lambda () (user-error "Don't know how to resolve")) "Mode-specific merge function. The function is called with zero or one argument (non-nil if the resolution function should only apply safe heuristics) and with the match data set according to `smerge-match-conflict'.") -(add-to-list 'debug-ignored-errors "Don't know how to resolve") +;;(add-to-list 'debug-ignored-errors "Don't know how to resolve") (defvar smerge-text-properties `(help-echo "merge conflict: mouse-3 shows a menu" @@ -742,9 +742,9 @@ (when base-start (1- base-start)) base-start (1- other-start) other-start)) t) - (search-failed (error "Point not in conflict region"))))) + (search-failed (user-error "Point not in conflict region"))))) -(add-to-list 'debug-ignored-errors "Point not in conflict region") +;;(add-to-list 'debug-ignored-errors "Point not in conflict region") (defun smerge-conflict-overlay (pos) "Return the conflict overlay at POS if any." Index: lisp/subr.el =================================================================== RCS file: /sources/emacs/emacs/lisp/subr.el,v retrieving revision 1.667 diff -b -u -r1.667 subr.el --- lisp/subr.el 25 Nov 2009 03:59:23 -0000 1.667 +++ lisp/subr.el 28 Nov 2009 00:55:12 -0000 @@ -239,6 +239,19 @@ (signal 'error (list (apply 'format args))))) (set-advertised-calling-convention 'error '(string &rest args)) +(defun user-error (&rest args) + "Signal an error that normally do not call the debugger. +Like the function `error' but signals 'user-error instead of +'error. By default this skips the debugger. +See `debug-ignored-errors' for more information." + (while t + (signal 'user-error (list (apply 'format args))))) +(set-advertised-calling-convention 'error '(string &rest args)) + +(put 'user-error 'error-message "Warning") +(put 'user-error 'error-conditions '(user-error)) +(setq debug-ignored-errors (cons 'user-error debug-ignored-errors)) + ;; We put this here instead of in frame.el so that it's defined even on ;; systems where frame.el isn't loaded. (defun frame-configuration-p (object) Index: lisp/terminal.el =================================================================== RCS file: /sources/emacs/emacs/lisp/terminal.el,v retrieving revision 1.70 diff -b -u -r1.70 terminal.el --- lisp/terminal.el 13 Nov 2009 22:19:55 -0000 1.70 +++ lisp/terminal.el 28 Nov 2009 02:14:34 -0000 @@ -1126,7 +1126,7 @@ (while (setq process (get-buffer-process (current-buffer))) (if (y-or-n-p (format "Kill process %s? " (process-name process))) (delete-process process) - (error "Process %s not killed" (process-name process))))) + (user-error "Process %s not killed" (process-name process))))) (condition-case err (let ((process-environment (cons (concat "TERM=" te-terminal-name) Index: lisp/calc/calc-undo.el =================================================================== RCS file: /sources/emacs/emacs/lisp/calc/calc-undo.el,v retrieving revision 1.19 diff -b -u -r1.19 calc-undo.el --- lisp/calc/calc-undo.el 5 Jan 2009 03:20:27 -0000 1.19 +++ lisp/calc/calc-undo.el 28 Nov 2009 01:04:57 -0000 @@ -35,14 +35,14 @@ (defun calc-undo (n) (interactive "p") (when calc-executing-macro - (error "Use C-x e, not X, to run a keyboard macro that uses Undo")) + (user-error "Use C-x e, not X, to run a keyboard macro that uses Undo")) (if (<= n 0) (if (< n 0) (calc-redo (- n)) (calc-last-args 1)) (calc-wrapper (when (null (nthcdr (1- n) calc-undo-list)) - (error "No further undo information available")) + (user-error "No further undo information available")) (setq calc-undo-list (prog1 (nthcdr n calc-undo-list) Index: lisp/calendar/calendar.el =================================================================== RCS file: /sources/emacs/emacs/lisp/calendar/calendar.el,v retrieving revision 1.292 diff -b -u -r1.292 calendar.el --- lisp/calendar/calendar.el 10 Nov 2009 08:11:51 -0000 1.292 +++ lisp/calendar/calendar.el 27 Nov 2009 22:58:16 -0000 @@ -1882,7 +1882,7 @@ ;; or on or before the digit of a 1-digit date. (if (not (and (looking-at "[ 0-9]?[0-9][^0-9]") (get-text-property (point) 'date))) - (if error (error "Not on a date!")) + (if error (user-error "Not on a date!")) ;; Convert segment to real month and year. (if (zerop month) (setq month 12)) ;; Go back to before the first date digit. @@ -1897,7 +1897,7 @@ ((and (= 1 month) (= segment 2)) (1+ displayed-year)) (t displayed-year)))))))) -(add-to-list 'debug-ignored-errors "Not on a date!") +;;(add-to-list 'debug-ignored-errors "Not on a date!") ;; The following version of calendar-gregorian-from-absolute is preferred for ;; reasons of clarity, BUT it's much slower than the version that follows it. Index: lisp/cedet/ede/autoconf-edit.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/ede/autoconf-edit.el,v retrieving revision 1.4 diff -b -u -r1.4 autoconf-edit.el --- lisp/cedet/ede/autoconf-edit.el 2 Oct 2009 10:53:34 -0000 1.4 +++ lisp/cedet/ede/autoconf-edit.el 28 Nov 2009 01:42:47 -0000 @@ -58,7 +58,7 @@ (if (file-exists-p cf1) cf1 cf2) )))) - (error "Quit")) + (user-error "Quit")) (find-file cf2))) ;; Note, we only ask about overwrite if a string/path is specified. (erase-buffer) Index: lisp/cedet/ede/pconf.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/ede/pconf.el,v retrieving revision 1.6 diff -b -u -r1.6 pconf.el --- lisp/cedet/ede/pconf.el 30 Oct 2009 02:16:42 -0000 1.6 +++ lisp/cedet/ede/pconf.el 28 Nov 2009 01:43:02 -0000 @@ -57,7 +57,7 @@ (not (eq ede-pconf-create-file-query 'never)) (not (y-or-n-p (format "I had to create the %s file for you. Ok? " file))) - (error "Quit"))))))) + (user-error "Quit"))))))) (defmethod ede-proj-configure-synchronize ((this ede-proj-project)) Index: lisp/cedet/ede/pmake.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/ede/pmake.el,v retrieving revision 1.6 diff -b -u -r1.6 pmake.el --- lisp/cedet/ede/pmake.el 17 Oct 2009 04:18:34 -0000 1.6 +++ lisp/cedet/ede/pmake.el 28 Nov 2009 01:43:25 -0000 @@ -85,7 +85,7 @@ (not (eobp)) (not (looking-at "# Automatically Generated \\w+ by EDE."))) (if (not (y-or-n-p (format "Really replace %s? " mfilename))) - (error "Not replacing Makefile")) + (user-error "Not replacing Makefile")) (message "Replace EDE Makefile")) (erase-buffer) (ede-srecode-setup) Index: lisp/cedet/ede/proj.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/ede/proj.el,v retrieving revision 1.9 diff -b -u -r1.9 proj.el --- lisp/cedet/ede/proj.el 30 Oct 2009 02:16:42 -0000 1.9 +++ lisp/cedet/ede/proj.el 28 Nov 2009 01:43:45 -0000 @@ -453,7 +453,7 @@ (df (project-dist-files this))) (if (and (file-exists-p (car df)) (not (y-or-n-p "Dist file already exists. Rebuild? "))) - (error "Try `ede-update-version' before making a distribution")) + (user-error "Try `ede-update-version' before making a distribution")) (ede-proj-setup-buildenvironment this) (if (string= (file-name-nondirectory pm) "Makefile.am") (setq pm (expand-file-name "Makefile" Index: lisp/cedet/ede/simple.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/ede/simple.el,v retrieving revision 1.3 diff -b -u -r1.3 simple.el --- lisp/cedet/ede/simple.el 2 Oct 2009 10:53:35 -0000 1.3 +++ lisp/cedet/ede/simple.el 28 Nov 2009 01:44:02 -0000 @@ -95,7 +95,7 @@ (if (y-or-n-p (concat ede-simple-save-directory " doesn't exist. Create? ")) (make-directory ede-simple-save-directory) - (error "No save directory for new project"))) + (user-error "No save directory for new project"))) (eieio-persistent-save proj)) (defmethod ede-find-subproject-for-directory ((proj ede-simple-project) Index: lisp/cedet/semantic/symref/list.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/semantic/symref/list.el,v retrieving revision 1.7 diff -b -u -r1.7 list.el --- lisp/cedet/semantic/symref/list.el 3 Nov 2009 21:45:32 -0000 1.7 +++ lisp/cedet/semantic/symref/list.el 28 Nov 2009 01:44:57 -0000 @@ -54,7 +54,7 @@ (when (not ct) (error "Place cursor inside tag to be searched for")) ;; Check w/ user. (when (not (y-or-n-p (format "Find references for %s? " (semantic-tag-name ct)))) - (error "Quit")) + (user-error "Quit")) ;; Gather results and tags (message "Gathering References...") (setq res (semantic-symref-find-references-by-name (semantic-tag-name ct))) Index: lisp/cedet/srecode/document.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/srecode/document.el,v retrieving revision 1.5 diff -b -u -r1.5 document.el --- lisp/cedet/srecode/document.el 3 Nov 2009 21:45:32 -0000 1.5 +++ lisp/cedet/srecode/document.el 28 Nov 2009 01:45:29 -0000 @@ -514,7 +514,7 @@ (pulse-momentary-highlight-region s e) (when (not (y-or-n-p "A comment already exists. Replace? ")) - (error "Quit")) + (user-error "Quit")) ;; Extract text from the existing comment. (srecode-extract temp s e) Index: lisp/cedet/srecode/getset.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/srecode/getset.el,v retrieving revision 1.5 diff -b -u -r1.5 getset.el --- lisp/cedet/srecode/getset.el 3 Nov 2009 21:45:31 -0000 1.5 +++ lisp/cedet/srecode/getset.el 28 Nov 2009 01:45:45 -0000 @@ -268,7 +268,7 @@ (if (or srecode-insert-getset-fully-automatic-flag (y-or-n-p "Insert new field here? ")) nil - (error "You must position the cursor where to insert the new field first")) + (user-error "You must position the cursor where to insert the new field first")) ) Index: lisp/cedet/srecode/map.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/srecode/map.el,v retrieving revision 1.10 diff -b -u -r1.10 map.el --- lisp/cedet/srecode/map.el 22 Nov 2009 23:49:20 -0000 1.10 +++ lisp/cedet/srecode/map.el 28 Nov 2009 01:46:15 -0000 @@ -287,7 +287,7 @@ (make-directory (file-name-directory srecode-map-save-file)) ;; No make, change save file (customize-variable 'srecode-map-save-file) - (error "Change your SRecode map file")))) + (user-error "Change your SRecode map file")))) ;; Have a dir. Make the object. (setq srecode-current-map (srecode-map "SRecode Map" Index: lisp/cedet/srecode/texi.el =================================================================== RCS file: /sources/emacs/emacs/lisp/cedet/srecode/texi.el,v retrieving revision 1.4 diff -b -u -r1.4 texi.el --- lisp/cedet/srecode/texi.el 3 Nov 2009 21:45:31 -0000 1.4 +++ lisp/cedet/srecode/texi.el 28 Nov 2009 01:46:34 -0000 @@ -61,7 +61,7 @@ (progn (goto-char (car (cdr nodebounds))) (if (not (y-or-n-p "Add menu here? ")) - (error "Abort")) + (user-error "Abort")) (srecode-insert "declaration:menu")) ;; Else, find the end (re-search-forward "@end menu") Index: lisp/emacs-lisp/authors.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emacs-lisp/authors.el,v retrieving revision 1.65 diff -b -u -r1.65 authors.el --- lisp/emacs-lisp/authors.el 31 Oct 2009 02:38:37 -0000 1.65 +++ lisp/emacs-lisp/authors.el 28 Nov 2009 01:57:56 -0000 @@ -865,7 +865,7 @@ (unless (file-exists-p (expand-file-name "src/emacs.c" root)) (unless (y-or-n-p (format "Not the root directory of Emacs: %s, continue? " root)) - (error "Not the root directory"))) + (user-error "Not the root directory"))) (dolist (log logs) (when (string-match "ChangeLog\\(.[0-9]+\\)?$" log) (message "Scanning %s..." log) Index: lisp/emacs-lisp/checkdoc.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emacs-lisp/checkdoc.el,v retrieving revision 1.81 diff -b -u -r1.81 checkdoc.el --- lisp/emacs-lisp/checkdoc.el 24 Nov 2009 23:13:09 -0000 1.81 +++ lisp/emacs-lisp/checkdoc.el 28 Nov 2009 01:35:57 -0000 @@ -922,7 +922,7 @@ (progn (goto-char wrong) (if (not take-notes) - (error "%s" (checkdoc-error-text msg))))) + (user-error "%s" (checkdoc-error-text msg))))) (checkdoc-show-diagnostics) (if (called-interactively-p 'interactive) (message "No style warnings.")))) @@ -955,7 +955,7 @@ (e (checkdoc-file-comments-engine)) (checkdoc-generate-compile-warnings-flag (or take-notes checkdoc-generate-compile-warnings-flag))) - (if e (error "%s" (checkdoc-error-text e))) + (if e (user-error "%s" (checkdoc-error-text e))) (checkdoc-show-diagnostics) e)) @@ -993,7 +993,7 @@ (if (not (called-interactively-p 'interactive)) e (if e - (error "%s" (checkdoc-error-text e)) + (user-error "%s" (checkdoc-error-text e)) (checkdoc-show-diagnostics))) (goto-char p)) (if (called-interactively-p 'interactive) @@ -1037,15 +1037,15 @@ (msg (checkdoc-this-string-valid))) (if msg (if no-error (message "%s" (checkdoc-error-text msg)) - (error "%s" (checkdoc-error-text msg))) + (user-error "%s" (checkdoc-error-text msg))) (setq msg (checkdoc-message-text-search beg end)) (if msg (if no-error (message "%s" (checkdoc-error-text msg)) - (error "%s" (checkdoc-error-text msg))) + (user-error "%s" (checkdoc-error-text msg))) (setq msg (checkdoc-rogue-space-check-engine beg end)) (if msg (if no-error (message "%s" (checkdoc-error-text msg)) - (error "%s" (checkdoc-error-text msg)))))) + (user-error "%s" (checkdoc-error-text msg)))))) (if (called-interactively-p 'interactive) (message "Checkdoc: done.")))))) @@ -2671,6 +2671,8 @@ (custom-add-option 'emacs-lisp-mode-hook (lambda () (checkdoc-minor-mode 1))) +;; Fix-me: Assumed that (checkdoc-error-text e) are for user +;; errors. Perhaps this catches the strings below too? (add-to-list 'debug-ignored-errors "Argument `.*' should appear (as .*) in the doc string") (add-to-list 'debug-ignored-errors Index: lisp/emacs-lisp/easy-mmode.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emacs-lisp/easy-mmode.el,v retrieving revision 1.99 diff -b -u -r1.99 easy-mmode.el --- lisp/emacs-lisp/easy-mmode.el 11 Nov 2009 06:17:10 -0000 1.99 +++ lisp/emacs-lisp/easy-mmode.el 28 Nov 2009 01:36:31 -0000 @@ -518,8 +518,8 @@ (when was-narrowed (,narrowfun))))))) (unless name (setq name base-name)) `(progn - (add-to-list 'debug-ignored-errors - ,(concat "^No \\(previous\\|next\\) " (regexp-quote name))) + ;; (add-to-list 'debug-ignored-errors + ;; ,(concat "^No \\(previous\\|next\\) " (regexp-quote name))) (defun ,next-sym (&optional count) ,(format "Go to the next COUNT'th %s." name) (interactive "p") @@ -530,7 +530,7 @@ `(if (not (re-search-forward ,re nil t count)) (if (looking-at ,re) (goto-char (or ,(if endfun `(,endfun)) (point-max))) - (error "No next %s" ,name)) + (user-error "No next %s" ,name)) (goto-char (match-beginning 0)) (when (and (eq (current-buffer) (window-buffer (selected-window))) (called-interactively-p 'interactive)) @@ -549,7 +549,7 @@ (if (< count 0) (,next-sym (- count)) ,(funcall when-narrowed `(unless (re-search-backward ,re nil t count) - (error "No previous %s" ,name))) + (user-error "No previous %s" ,name))) ,@body)) (put ',prev-sym 'definition-name ',base)))) Index: lisp/emulation/edt.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emulation/edt.el,v retrieving revision 1.70 diff -b -u -r1.70 edt.el --- lisp/emulation/edt.el 3 Nov 2009 02:04:34 -0000 1.70 +++ lisp/emulation/edt.el 28 Nov 2009 01:59:56 -0000 @@ -2085,11 +2085,11 @@ "Ah yes, there it is, in \n\n %s \n\n" path)) (if (edt-y-or-n-p "Do you want to run it now? ") (load-file path) - (error "EDT Emulation not configured"))) + (user-error "EDT Emulation not configured"))) (t (insert "Nope, I can't seem to find it. :-(\n\n") (sit-for 20) - (error "EDT Emulation not configured"))))))) + (user-error "EDT Emulation not configured"))))))) ;;; ;;; Turning the EDT Emulation on and off. Index: lisp/emulation/viper-cmd.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emulation/viper-cmd.el,v retrieving revision 1.87 diff -b -u -r1.87 viper-cmd.el --- lisp/emulation/viper-cmd.el 22 Nov 2009 03:14:15 -0000 1.87 +++ lisp/emulation/viper-cmd.el 28 Nov 2009 02:01:00 -0000 @@ -4077,7 +4077,7 @@ "Buffer `%s' is modified, are you sure you want to kill it? " buffer-name))) (kill-buffer buffer) - (error "Buffer not killed")))) + (user-error "Buffer not killed")))) @@ -5077,7 +5077,7 @@ (if (y-or-n-p "Mail anyway? ") () (set-window-configuration window-config) - (error "Bug report aborted"))) + (user-error "Bug report aborted"))) (require 'reporter) (set-window-configuration window-config) Index: lisp/emulation/viper-macs.el =================================================================== RCS file: /sources/emacs/emacs/lisp/emulation/viper-macs.el,v retrieving revision 1.47 diff -b -u -r1.47 viper-macs.el --- lisp/emulation/viper-macs.el 5 Jan 2009 03:21:21 -0000 1.47 +++ lisp/emulation/viper-macs.el 28 Nov 2009 02:01:58 -0000 @@ -888,7 +888,7 @@ (if (get-register reg) (if (y-or-n-p "Register contains data. Overwrite? ") () - (error + (user-error "Macro not saved in register. Can still be invoked via `C-x e'"))) (set-register reg last-kbd-macro)) Index: lisp/gnus/gnus-art.el =================================================================== RCS file: /sources/emacs/emacs/lisp/gnus/gnus-art.el,v retrieving revision 1.188 diff -b -u -r1.188 gnus-art.el --- lisp/gnus/gnus-art.el 24 Oct 2009 03:42:19 -0000 1.188 +++ lisp/gnus/gnus-art.el 28 Nov 2009 02:07:33 -0000 @@ -8318,7 +8318,7 @@ (when (and gnus-article-encrypt-protocol gnus-novice-user) (unless (gnus-y-or-n-p "Really encrypt article(s)? ") - (error "Encrypt aborted"))) + (user-error "Encrypt aborted"))) (let ((func (cdr (assoc protocol gnus-article-encrypt-protocol-alist)))) (unless func (error "Can't find the encrypt protocol %s" protocol)) Index: lisp/gnus/gnus-draft.el =================================================================== RCS file: /sources/emacs/emacs/lisp/gnus/gnus-draft.el,v retrieving revision 1.25 diff -b -u -r1.25 gnus-draft.el --- lisp/gnus/gnus-draft.el 3 Mar 2009 10:18:45 -0000 1.25 +++ lisp/gnus/gnus-draft.el 28 Nov 2009 02:08:25 -0000 @@ -240,7 +240,7 @@ (if (and active (>= (cdr active) (car active))) (if (y-or-n-p "There are unsent drafts. Confirm to exit? ") (throw 'continue t) - (error "Stop!")))))))) + (user-error "Stop!")))))))) (defcustom gnus-draft-setup-hook nil "Hook run after setting up a draft buffer." Index: lisp/gnus/gnus-score.el =================================================================== RCS file: /sources/emacs/emacs/lisp/gnus/gnus-score.el,v retrieving revision 1.40 diff -b -u -r1.40 gnus-score.el --- lisp/gnus/gnus-score.el 5 Jan 2009 03:22:03 -0000 1.40 +++ lisp/gnus/gnus-score.el 28 Nov 2009 02:09:02 -0000 @@ -925,7 +925,7 @@ (string-to-number (read-string "Score: ")))) (save-excursion (unless (and (stringp match) (> (length match) 0)) - (error "No match")) + (user-error "No match")) (goto-char (point-min)) (let ((regexp (cond ((eq type 'f) (gnus-simplify-subject-fuzzy match)) Index: lisp/gnus/message.el =================================================================== RCS file: /sources/emacs/emacs/lisp/gnus/message.el,v retrieving revision 1.176 diff -b -u -r1.176 message.el --- lisp/gnus/message.el 24 Nov 2009 09:19:09 -0000 1.176 +++ lisp/gnus/message.el 28 Nov 2009 02:12:13 -0000 @@ -4285,7 +4285,7 @@ (not (y-or-n-p (format "Address `%s' might be bogus. Continue? " bog))) - (error "Bogus address")))))))) + (user-error "Bogus address")))))))) (custom-add-option 'message-setup-hook 'message-check-recipients) @@ -4431,7 +4431,7 @@ (insert " ") (forward-line 1) (unless (y-or-n-p "Send anyway? ") - (error "Failed to send the message"))))) + (user-error "Failed to send the message"))))) ;; Let the user do all of the above. (run-hooks 'message-header-hook)) (unwind-protect @@ -6189,7 +6189,7 @@ (y-or-n-p "Message already being composed; erase? ") (message nil)))) - (error "Message being composed"))) + (user-error "Message being composed"))) (funcall (or switch-function 'pop-to-buffer) name) (set-buffer name)) (erase-buffer) Index: lisp/mh-e/mh-utils.el =================================================================== RCS file: /sources/emacs/emacs/lisp/mh-e/mh-utils.el,v retrieving revision 1.76 diff -b -u -r1.76 mh-utils.el --- lisp/mh-e/mh-utils.el 4 Oct 2009 02:11:59 -0000 1.76 +++ lisp/mh-e/mh-utils.el 27 Nov 2009 23:29:08 -0000 @@ -350,10 +350,10 @@ (string-to-number (buffer-substring (match-beginning 1) (match-end 1)))) (error-if-no-message - (error "Cursor not pointing to message")) + (user-error "Cursor not pointing to message")) (t nil)))) -(add-to-list 'debug-ignored-errors "^Cursor not pointing to message$") +;;(add-to-list 'debug-ignored-errors "^Cursor not pointing to message$") Index: lisp/org/org-agenda.el =================================================================== RCS file: /sources/emacs/emacs/lisp/org/org-agenda.el,v retrieving revision 1.39 diff -b -u -r1.39 org-agenda.el --- lisp/org/org-agenda.el 20 Nov 2009 20:50:32 -0000 1.39 +++ lisp/org/org-agenda.el 28 Nov 2009 01:05:39 -0000 @@ -1689,12 +1689,12 @@ that have been changed along." (interactive) (or org-agenda-allow-remote-undo - (error "Check the variable `org-agenda-allow-remote-undo' to activate remote undo")) + (user-error "Check the variable `org-agenda-allow-remote-undo' to activate remote undo")) (if (not (eq this-command last-command)) (setq org-agenda-undo-has-started-in nil org-agenda-pending-undo-list org-agenda-undo-list)) (if (not org-agenda-pending-undo-list) - (error "No further undo information")) + (user-error "No further undo information")) (let* ((entry (pop org-agenda-pending-undo-list)) buf line cmd rembuf) (setq cmd (pop entry) line (pop entry)) Index: lisp/play/decipher.el =================================================================== RCS file: /sources/emacs/emacs/lisp/play/decipher.el,v retrieving revision 1.38 diff -b -u -r1.38 decipher.el --- lisp/play/decipher.el 3 Nov 2009 02:04:35 -0000 1.38 +++ lisp/play/decipher.el 28 Nov 2009 01:06:01 -0000 @@ -389,11 +389,11 @@ ;; for the following command. (setq this-command t) (or (eq major-mode 'decipher-mode) - (error "This buffer is not in Decipher mode")) + (user-error "This buffer is not in Decipher mode")) (or (eq last-command 'decipher-undo) (setq decipher-pending-undo-list decipher-undo-list)) (or decipher-pending-undo-list - (error "No further undo information")) + (user-error "No further undo information")) (let ((undo-rec (pop decipher-pending-undo-list)) buffer-read-only ;Make buffer writable redo-map redo-rec undo-map) Index: lisp/progmodes/compile.el =================================================================== RCS file: /sources/emacs/emacs/lisp/progmodes/compile.el,v retrieving revision 1.504 diff -b -u -r1.504 compile.el --- lisp/progmodes/compile.el 12 Nov 2009 06:55:43 -0000 1.504 +++ lisp/progmodes/compile.el 27 Nov 2009 23:30:42 -0000 @@ -2277,6 +2277,7 @@ compilation-locs)) compilation-locs)))) +;; Fix-me: How should this be handled? (add-to-list 'debug-ignored-errors "^No more [-a-z ]+s yet$") ;;; Compatibility with the old compile.el. Index: lisp/progmodes/etags.el =================================================================== RCS file: /sources/emacs/emacs/lisp/progmodes/etags.el,v retrieving revision 1.217 diff -b -u -r1.217 etags.el --- lisp/progmodes/etags.el 25 Nov 2009 06:08:45 -0000 1.217 +++ lisp/progmodes/etags.el 27 Nov 2009 23:36:25 -0000 @@ -552,7 +552,7 @@ (cond ((eq cont 'same) ;; Use the ambient value of tags-file-name. (or tags-file-name - (error "%s" + (user-error "%s" (substitute-command-keys (concat "No tags table in use; " "use \\[visit-tags-table] to select one"))))) @@ -704,7 +704,7 @@ (kill-local-variable 'tags-file-name) (if (eq local-tags-file-name tags-file-name) (setq tags-file-name nil)) - (error "File %s is not a valid tags table" local-tags-file-name))))) + (user-error "File %s is not a valid tags table" local-tags-file-name))))) (defun tags-reset-tags-tables () "Reset tags state to cancel effect of any previous \\[visit-tags-table] or \\[find-tag]." @@ -804,7 +804,7 @@ (tags-lazy-completion-table) nil nil nil nil default))) (if (equal spec "") - (or default (error "There is no default tag")) + (or default (user-error "There is no default tag")) spec))) (defvar last-tag nil @@ -858,7 +858,7 @@ (if (eq '- next-p) ;; Pop back to a previous location. (if (ring-empty-p tags-location-ring) - (error "No previous tag locations") + (user-error "No previous tag locations") (let ((marker (ring-remove tags-location-ring 0))) (prog1 ;; Move to the saved location. @@ -1367,7 +1367,7 @@ offset (* 3 offset))) ; expand search window (or found (re-search-forward pat nil t) - (error "Rerun etags: `%s' not found in %s" + (user-error "Rerun etags: `%s' not found in %s" pat buffer-file-name))) ;; Position point at the right place ;; if the search string matched an extra Ctrl-m at the beginning. @@ -1713,7 +1713,7 @@ (and novisit (get-buffer " *next-file*") (kill-buffer " *next-file*")) - (error "All files processed")) + (user-error "All files processed")) (let* ((next (car next-file-list)) (buffer (get-file-buffer next)) (new (not buffer))) @@ -1746,7 +1746,7 @@ "Form for `tags-loop-continue' to eval to change one file.") (defvar tags-loop-scan - '(error "%s" + '(user-error "%s" (substitute-command-keys "No \\[tags-search] or \\[tags-query-replace] in progress")) "Form for `tags-loop-continue' to eval to scan one file. @@ -1904,7 +1904,7 @@ (if (funcall list-tags-function file) (setq gotany t))) (or gotany - (error "File %s not in current tags tables" file))))) + (user-error "File %s not in current tags tables" file))))) (with-current-buffer "*Tags List*" (require 'apropos) (with-no-warnings @@ -2037,7 +2037,7 @@ (interactive) (or tags-table-list tags-file-name - (error "%s" + (user-error "%s" (substitute-command-keys "No tags table loaded; try \\[visit-tags-table]"))) (let ((completion-ignore-case (if (memq tags-case-fold-search '(t nil)) @@ -2049,23 +2049,23 @@ (comp-table (tags-lazy-completion-table)) beg) (or pattern - (error "Nothing to complete")) + (user-error "Nothing to complete")) (search-backward pattern) (setq beg (point)) (forward-char (length pattern)) (completion-in-region beg (point) comp-table))) -(dolist (x '("^No tags table in use; use .* to select one$" - "^There is no default tag$" - "^No previous tag locations$" - "^File .* is not a valid tags table$" - "^No \\(more \\|\\)tags \\(matching\\|containing\\) " - "^Rerun etags: `.*' not found in " - "^All files processed$" - "^No .* or .* in progress$" - "^File .* not in current tags tables$" - "^No tags table loaded" - "^Nothing to complete$")) +(dolist (x '(;;"^No tags table in use; use .* to select one$" + ;;"^There is no default tag$" + ;;"^No previous tag locations$" + ;;"^File .* is not a valid tags table$" + "^No \\(more \\|\\)tags \\(matching\\|containing\\) " ;; Can't find it + ;;"^Rerun etags: `.*' not found in " + ;;"^All files processed$" + ;;"^No .* or .* in progress$" + ;;"^File .* not in current tags tables$" + ;;"^No tags table loaded" + ;;"^Nothing to complete$")) (add-to-list 'debug-ignored-errors x)) (provide 'etags) Index: lisp/progmodes/python.el =================================================================== RCS file: /sources/emacs/emacs/lisp/progmodes/python.el,v retrieving revision 1.101 diff -b -u -r1.101 python.el --- lisp/progmodes/python.el 6 Nov 2009 05:16:30 -0000 1.101 +++ lisp/progmodes/python.el 27 Nov 2009 23:37:34 -0000 @@ -1773,7 +1773,7 @@ (format "Describe symbol (default %s): " symbol) "Describe symbol: ") nil nil symbol)))) - (if (equal symbol "") (error "No symbol")) + (if (equal symbol "") (user-error "No symbol")) ;; Ensure we have a suitable help buffer. ;; Fixme: Maybe process `Related help topics' a la help xrefs and ;; allow C-c C-f in help buffer. @@ -1793,7 +1793,7 @@ symbol python-imports) "*Help*" (python-proc) nil nil)) -(add-to-list 'debug-ignored-errors "^No symbol") +;;(add-to-list 'debug-ignored-errors "^No symbol") (defun python-send-receive (string) "Send STRING to inferior Python (if any) and return result. @@ -2022,11 +2022,11 @@ (while (< (point) end) (if (and (< (current-indentation) count) (not (looking-at "[ \t]*$"))) - (error "Can't shift all lines enough")) + (user-error "Can't shift all lines enough")) (forward-line)) (indent-rigidly start end (- count))))) -(add-to-list 'debug-ignored-errors "^Can't shift all lines enough") +;;(add-to-list 'debug-ignored-errors "^Can't shift all lines enough") (defun python-shift-right (start end &optional count) "Shift lines in region COUNT (the prefix arg) columns to the right. Index: lisp/term/ns-win.el =================================================================== RCS file: /sources/emacs/emacs/lisp/term/ns-win.el,v retrieving revision 1.57 diff -b -u -r1.57 ns-win.el --- lisp/term/ns-win.el 3 Nov 2009 02:04:35 -0000 1.57 +++ lisp/term/ns-win.el 28 Nov 2009 02:14:46 -0000 @@ -898,7 +898,7 @@ `(mouse-1 POSITION 1)))) (if (y-or-n-p (format "Print buffer %s? " (buffer-name))) (print-buffer) - (error "Cancelled"))) + (user-error "Cancelled"))) (print-buffer))) Index: lisp/textmodes/ispell.el =================================================================== RCS file: /sources/emacs/emacs/lisp/textmodes/ispell.el,v retrieving revision 1.264 diff -b -u -r1.264 ispell.el --- lisp/textmodes/ispell.el 12 Nov 2009 06:55:44 -0000 1.264 +++ lisp/textmodes/ispell.el 27 Nov 2009 23:38:33 -0000 @@ -1820,7 +1820,7 @@ (if ispell-check-only ;; return dummy word when just flagging misspellings (list "" (point) (point)) - (error "No word found to check!")) + (user-error "No word found to check!")) (setq start (copy-marker (match-beginning 0)) end (point-marker) word (buffer-substring-no-properties start end)) @@ -3879,7 +3879,7 @@ (insert comment-end))))) (insert (concat " " word)))))))) -(add-to-list 'debug-ignored-errors "^No word found to check!$") +;;(add-to-list 'debug-ignored-errors "^No word found to check!$") (provide 'ispell)