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

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

bug#28566: 25.2; show-paren error


From: Live System User
Subject: bug#28566: 25.2; show-paren error
Date: Sat, 23 Sep 2017 06:43:10 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Eli Zaretskii <address@hidden> writes:

>> From: Live System User <address@hidden>
>> Date: Sat, 23 Sep 2017 05:58:56 -0400
>> 
>>         I got the following backtrace error while idle when the
>>         `show-paren-function`timer went off.
>> 
>>         I don't have a reproducible receipe so please close this
>>         bug report if this information is insufficient.
>> 
>>         Thanks.
>> 
>> Debugger entered--Lisp error: (wrong-type-argument stringp t)
>>   message(t)
>>   (if (not (null matching-text)) (message matching-text))
>>   (let ((matching-text nil)) (if (char-equal (char-syntax (or (or 
>> (char-before (point)) (char-after (point))) 48)) 41) (setq matching-text 
>> (blink-matching-open))) (if (not (null matching-text)) (message 
>> matching-text)))
>>   (let (ad-return-value) (setq ad-return-value (with-no-warnings (funcall 
>> ad--addoit-function))) (let ((matching-text nil)) (if (char-equal 
>> (char-syntax (or (or (char-before ...) (char-after ...)) 48)) 41) (setq 
>> matching-text (blink-matching-open))) (if (not (null matching-text)) 
>> (message matching-text))) ad-return-value)
>>   ad-Advice-show-paren-function(#[nil "\205    
>> \211\204\306!\210\306\f!\202\
>
> This seems to say you have some advice installed for
> show-paren-function.  As the string "matching-text" doesn't appear
> anywhere in paren.el (nor anywhere else in the Emacs sources), I'm
> guessing that it comes from that advice, and therefore the root cause
> for the error should be looked for in that advice.
>
> Can you tell what advice do you have for show-paren-function?


;; Show offscreen paren matches in the minibuffer
(defadvice show-paren-function
 (after show-matching-paren-offscreen activate)
 "If the matching paren is offscreen, show the matching line in the
   echo area. Has no effect if the character before point is not of
   the syntax class ')'."
 (interactive)
 (let ((matching-text nil))
   ;; Only call `blink-matching-open' if the character before point is a close
   ;; parentheses type character. Otherwise, there's not really any point, and
   ;; `blink-matching-open' would just echo "Mismatched parentheses", which gets
   ;; really annoying.
   ;; (or ...) is a hack to handle (bobp, eobp) conditions under 24.x.
   (if (char-equal (char-syntax
                     (or (or (char-before (point)) (char-after (point))) ?0)
                     ) ?\))
       (setq matching-text (blink-matching-open)))
   (if (not (null matching-text))
       (message matching-text))))





reply via email to

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