aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2007-10-16 02:41:08 +0000
committerGlenn Morris2007-10-16 02:41:08 +0000
commitbf825c621d0239098ae36834af0cd5b0b513d6a9 (patch)
treec67afb04041db569a5897a7bf17aa2e6cfa33fd3
parent745dc723d967d3a880b2a560e4b87b58c94e89cc (diff)
downloademacs-bf825c621d0239098ae36834af0cd5b0b513d6a9.tar.gz
emacs-bf825c621d0239098ae36834af0cd5b0b513d6a9.zip
Re-fill copyright header.
(blink-matching-open): Don't report false errors with the `$' syntax class.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/simple.el19
2 files changed, 20 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 274d26d7d57..17135a37a33 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12007-10-16 Glenn Morris <rgm@gnu.org>
2
3 * simple.el (blink-matching-open): Don't report false errors with
4 the `$' syntax class.
5
12007-10-16 Richard Stallman <rms@gnu.org> 62007-10-16 Richard Stallman <rms@gnu.org>
2 7
3 * emacs-lisp/advice.el (ad-get-advice-info): Change to a function. 8 * emacs-lisp/advice.el (ad-get-advice-info): Change to a function.
diff --git a/lisp/simple.el b/lisp/simple.el
index 1cfaf6bca22..b5ca79de027 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -1,7 +1,8 @@
1;;; simple.el --- basic editing commands for Emacs 1;;; simple.el --- basic editing commands for Emacs
2 2
3;; Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 3;; Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4;; 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. 4;; 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
5;; Free Software Foundation, Inc.
5 6
6;; Maintainer: FSF 7;; Maintainer: FSF
7;; Keywords: internal 8;; Keywords: internal
@@ -4657,6 +4658,8 @@ it skips the contents of comments that end before point."
4657 (point)))))) 4658 (point))))))
4658 (let* ((oldpos (point)) 4659 (let* ((oldpos (point))
4659 (message-log-max nil) ; Don't log messages about paren matching. 4660 (message-log-max nil) ; Don't log messages about paren matching.
4661 (atdollar (eq (syntax-class (syntax-after (1- oldpos))) 8))
4662 (isdollar)
4660 (blinkpos 4663 (blinkpos
4661 (save-excursion 4664 (save-excursion
4662 (save-restriction 4665 (save-restriction
@@ -4674,20 +4677,28 @@ it skips the contents of comments that end before point."
4674 (matching-paren 4677 (matching-paren
4675 (and blinkpos 4678 (and blinkpos
4676 ;; Not syntax '$'. 4679 ;; Not syntax '$'.
4677 (not (eq (syntax-class (syntax-after blinkpos)) 8)) 4680 (not (setq isdollar
4681 (eq (syntax-class (syntax-after blinkpos)) 8)))
4678 (let ((syntax (syntax-after blinkpos))) 4682 (let ((syntax (syntax-after blinkpos)))
4679 (and (consp syntax) 4683 (and (consp syntax)
4680 (eq (syntax-class syntax) 4) 4684 (eq (syntax-class syntax) 4)
4681 (cdr syntax)))))) 4685 (cdr syntax))))))
4682 (cond 4686 (cond
4683 ((not (or (eq matching-paren (char-before oldpos)) 4687 ;; isdollar is for:
4688 ;; http://lists.gnu.org/archive/html/emacs-devel/2007-10/msg00871.html
4689 ((not (or (and isdollar blinkpos)
4690 (and atdollar (not blinkpos)) ; see below
4691 (eq matching-paren (char-before oldpos))
4684 ;; The cdr might hold a new paren-class info rather than 4692 ;; The cdr might hold a new paren-class info rather than
4685 ;; a matching-char info, in which case the two CDRs 4693 ;; a matching-char info, in which case the two CDRs
4686 ;; should match. 4694 ;; should match.
4687 (eq matching-paren (cdr (syntax-after (1- oldpos)))))) 4695 (eq matching-paren (cdr (syntax-after (1- oldpos))))))
4688 (message "Mismatched parentheses")) 4696 (message "Mismatched parentheses"))
4689 ((not blinkpos) 4697 ((not blinkpos)
4690 (if (not blink-matching-paren-distance) 4698 (or blink-matching-paren-distance
4699 ;; Don't complain when `$' with no blinkpos, because it
4700 ;; could just be the first one typed in the buffer.
4701 atdollar
4691 (message "Unmatched parenthesis"))) 4702 (message "Unmatched parenthesis")))
4692 ((pos-visible-in-window-p blinkpos) 4703 ((pos-visible-in-window-p blinkpos)
4693 ;; Matching open within window, temporarily move to blinkpos but only 4704 ;; Matching open within window, temporarily move to blinkpos but only