emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Begging for show-paren change???


From: RGB
Subject: Re: Begging for show-paren change???
Date: Tue, 15 Nov 2005 20:49:44 -0600

So I just suggest the patch below instead.

Whatever way you want is fine with me.
I tried this for a while just to be sure but naturally it works just fine.
Looking forward to seeing it in CVS!
Thanks much.

       Stefan


--- paren.el 20 aoĆ» 2005 19:26:11 -0400 1.64
+++ paren.el 13 nov 2005 17:37:23 -0500
@@ -181,7 +181,12 @@
        (cdr (syntax-after beg)))
    (eq (char-after beg)
        ;; This can give nil.
-        (cdr (syntax-after (1- end)))))))))))))
+        (cdr (syntax-after (1- end))))
+                                   ;; The cdr might hold a new paren-class
+                                   ;; info rather than a matching-char info,
+                                   ;; in which case the two CDRs should match.
+                                   (eq (cdr (syntax-after (1- end)))
+                                       (cdr (syntax-after beg))))))))))))
 ;;
 ;; Highlight the other end of the sexp, or unhighlight if none.
 (if (not pos)

--- simple.el 12 Nov 2005 00:10:56 -0000 1.762
+++ simple.el 13 Nov 2005 22:38:39 -0000
@@ -4314,9 +4314,8 @@
   (eq (syntax-class syntax) 4)
   (cdr syntax)))))
 (cond
- ((or (null matching-paren)
-       (/= (char-before oldpos)
-   matching-paren))
+ ((not (or (eq matching-paren (char-before oldpos))
+                 (eq matching-paren (cdr (syntax-after oldpos)))))
   (message "Mismatched parentheses"))
 ((not blinkpos)
   (if (not blink-matching-paren-distance)






reply via email to

[Prev in Thread] Current Thread [Next in Thread]