From: Richard M. Stallman Date: Mon, 2 Oct 2006 02:30:06 +0000 (+0000) Subject: (undo-elt-crosses-region): Fix the inequalities. X-Git-Url: https://git.hcoop.net/bpt/emacs.git/commitdiff_plain/1f8a132d060bc079ff723466518b5ac4ef4ba6b6 (undo-elt-crosses-region): Fix the inequalities. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ade0bda636..9deec93eb2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2006-10-01 Johan Bockg,Ae(Brd + + * simple.el (undo-elt-crosses-region): Fix the inequalities. + 2006-10-01 Stefan Monnier * emacs-lisp/find-func.el (find-function-regexp): Don't match diff --git a/lisp/simple.el b/lisp/simple.el index 105c5a9afc..8bd3a30a59 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -1648,12 +1648,12 @@ is not *inside* the region START...END." ((null (car undo-elt)) ;; (nil PROPERTY VALUE BEG . END) (let ((tail (nthcdr 3 undo-elt))) - (not (or (< (car tail) end) - (> (cdr tail) start))))) + (and (< (car tail) end) + (> (cdr tail) start)))) ((integerp (car undo-elt)) ;; (BEGIN . END) - (not (or (< (car undo-elt) end) - (> (cdr undo-elt) start)))))) + (and (< (car undo-elt) end) + (> (cdr undo-elt) start))))) ;; Return the first affected buffer position and the delta for an undo element ;; delta is defined as the change in subsequent buffer positions if we *did*