GNU bug report logs - #31155
26.1; electric-pair-mode sometimes inserts extra ) in process buffers

Previous Next

Package: emacs;

Reported by: Alex Branham <alex.branham <at> gmail.com>

Date: Sat, 14 Apr 2018 21:06:01 UTC

Severity: normal

Tags: moreinfo

Found in version 26.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #25 received at 31155 <at> debbugs.gnu.org (full text, mbox):

From: Noam Postavsky <npostavs <at> gmail.com>
To: Alex Branham <alex.branham <at> gmail.com>
Cc: 31155 <at> debbugs.gnu.org
Subject: Re: bug#31155: 26.1;
 electric-pair-mode sometimes inserts extra ) in process buffers
Date: Mon, 23 Apr 2018 19:23:15 -0400
Alex Branham <alex.branham <at> gmail.com> writes:

> Sorry for taking so long to respond, it is difficult to capture this
> happening.

No worries, it takes as long as it takes.

> 1 -> (electric-pair-syntax-info 91)
> 1 <- electric-pair-syntax-info: (40 93 nil 79153)
> ======================================================================
> 1 -> (electric-pair--balance-info 1 79153)
> 1 <- electric-pair--balance-info: ((nil . 93) nil . 93)

> This happened when I typed (in an inferior R buffer):
>
> Rhats[[

Ah, this is a slightly different scenario than I thought, we're missing
close brackets, rather than inserting too many.  The
electric-pair--balance-info seems to be saying that you're inside a
string or comment.  Was that the case?  Or was there a stray quote in
the buffer?

Anyway, I think tracing a few more functions will be helpful:

    (dolist (fun '(electric-pair--balance-info
                   electric-pair-skip-if-helps-balance
                   electric-pair-inhibit-if-helps-balance
                   electric-pair-syntax-info
                   electric-pair-default-inhibit
                   electric-pair-default-skip-self
                   electric-pair-post-self-insert-function))
      (trace-function-background fun))




This bug report was last modified 5 years and 234 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.