Re: electric-pair mode, comint, and text attribution
Augusto Stoffel <[email protected]>
| Newsgroups | gmane.emacs.devel |
|---|---|
| Message-ID | <[email protected]> |
Related, if not exactly the same issue: bug#50236 On Fri, 3 Jul 2026, Andrew Hyatt wrote: > Stefan Monnier via "Emacs development discussions." <[email protected]> writes: > > Perhaps this is just a bug and I should report it as a bug, but I think if I did so, it'd > probably be closed as working as intended. In a way, it is. Electric pair mode is > doing what is says it would do. However, I think it'd be better if comint-mode and > similar modes would track, probably with overlays, which parts of the buffer are > definitely known to be generated, and those parts are excluded from electric-pair > mode. > > I think this is indeed just a bug (or a missing feature) in electric-pair-mode. > > The bug might arguably be in the corresponding modes for failing to tell > `electric-pair-mode` how it should behave. Tho it may also be a bug in > `electric-pair-mode` for failing to offer appropriate hooks. I recommend you `M-x > report-emacs-bug`. > > I'll do that. However, I think the design decisions are interesting, and spill beyond just > electric-pair-mode for the reasons I've mentioned above; I'd rather think about a fix that > solves this in a way that enhances Emacs more generally. I'm happy to write a more > specific proposal if there's interest in the problem, and I'll mention that in the bug report. > > = Stefan