changeset 4040:d06d7295d3eb

Put error-conditions and error-message properties on 'mark-inactive. (mark): Signal 'mark-inactive instead of using error with a message.
author Roland McGrath <roland@gnu.org>
date Thu, 08 Jul 1993 21:46:22 +0000
parents 77cb08d1c4a5
children b145227c647a
files lisp/simple.el
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/simple.el	Thu Jul 08 21:43:11 1993 +0000
+++ b/lisp/simple.el	Thu Jul 08 21:46:22 1993 +0000
@@ -1244,6 +1244,9 @@
 turns off region highlighting, but commands that use the mark
 behave as if the mark were still active.")
 
+(put 'mark-inactive 'error-conditions '(mark-inactive error))
+(put 'mark-inactive 'error-message "The mark is not active now")
+
 (defun mark (&optional force)
   "Return this buffer's mark value as integer; error if mark inactive.
 If optional argument FORCE is non-nil, access the mark value
@@ -1254,7 +1257,7 @@
 a mistake; see the documentation of `set-mark'."
   (if (or force mark-active mark-even-if-inactive)
       (marker-position (mark-marker))
-    (error "The mark is not currently active")))
+    (signal 'mark-inactive nil)))
 
 (defun set-mark (pos)
   "Set this buffer's mark to POS.  Don't use this function!