[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Timer scheduling and cancel-timer
From: |
Bastien |
Subject: |
Re: Timer scheduling and cancel-timer |
Date: |
Tue, 22 Jan 2013 14:57:49 +0100 |
User-agent: |
Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) |
Stefan Monnier <address@hidden> writes:
>> Perhaps it is worth reverting the code change you made that makes this happen
>> now, until you find the bug?
>
> No, the change is there specifically to avoid hiding bugs under the
> rug.
The attached patch fixes the bug.
Can anyone confirm this?
=== modified file 'lisp/paren.el'
--- lisp/paren.el 2013-01-01 09:11:05 +0000
+++ lisp/paren.el 2013-01-22 13:55:42 +0000
@@ -243,23 +243,23 @@
;;
;; Turn on highlighting for the matching paren, if found.
;; If it's an unmatched paren, turn off any such highlighting.
- (unless (integerp pos)
- (delete-overlay show-paren-overlay))
- (let ((to (if (or (eq show-paren-style 'expression)
- (and (eq show-paren-style 'mixed)
- (not (pos-visible-in-window-p pos))))
- (point)
- pos))
- (from (if (or (eq show-paren-style 'expression)
+ (if (not (integerp pos))
+ (when show-paren-overlay (delete-overlay show-paren-overlay))
+ (let ((to (if (or (eq show-paren-style 'expression)
(and (eq show-paren-style 'mixed)
(not (pos-visible-in-window-p pos))))
- pos
- (save-excursion
- (goto-char pos)
- (- (point) dir)))))
- (if show-paren-overlay
- (move-overlay show-paren-overlay from to (current-buffer))
- (setq show-paren-overlay (make-overlay from to nil t))))
+ (point)
+ pos))
+ (from (if (or (eq show-paren-style 'expression)
+ (and (eq show-paren-style 'mixed)
+ (not (pos-visible-in-window-p pos))))
+ pos
+ (save-excursion
+ (goto-char pos)
+ (- (point) dir)))))
+ (if show-paren-overlay
+ (move-overlay show-paren-overlay from to (current-buffer))
+ (setq show-paren-overlay (make-overlay from to nil t)))))
;;
;; Always set the overlay face, since it varies.
(overlay-put show-paren-overlay 'priority show-paren-priority)
--
Bastien
- Timer scheduling and cancel-timer, Tomohiro Matsuyama, 2013/01/20
- Re: Timer scheduling and cancel-timer, Paul Eggert, 2013/01/20
- RE: Timer scheduling and cancel-timer, Drew Adams, 2013/01/20
- RE: Timer scheduling and cancel-timer, Drew Adams, 2013/01/20
- Re: Timer scheduling and cancel-timer, Stefan Monnier, 2013/01/20
- RE: Timer scheduling and cancel-timer, Drew Adams, 2013/01/20
- RE: Timer scheduling and cancel-timer, Drew Adams, 2013/01/21
- Re: Timer scheduling and cancel-timer, Stephen Berman, 2013/01/22
- Re: Timer scheduling and cancel-timer, Stefan Monnier, 2013/01/22
- Re: Timer scheduling and cancel-timer,
Bastien <=
- Re: Timer scheduling and cancel-timer, Stefan Monnier, 2013/01/22