From: Allen Li <darkfeline@felesatra.moe>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Lars Ingebrigtsen <larsi@gnus.org>, 49629@debbugs.gnu.org
Subject: bug#49629: 27.2; electric-pair-mode doesn't work for angle brackets in HTML file
Date: Fri, 24 Dec 2021 02:07:54 -0800 [thread overview]
Message-ID: <80zgoq48p1.fsf@felesatra.moe> (raw)
In-Reply-To: <jwv5yrxx5z7.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Thu, 09 Dec 2021 08:30:24 -0500")
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>> I have bisected this regression to 7fff418edf56244a1fcf54718523aa9b5cb3a854
>>
>> I will cc Stefan on the miniscule chance he still remembers anything about
>> this and can save me time.
>> Otherwise, I will see if I can pinpoint the regression (or if I messed up
>> the bisect).
>
> Hmm... I do vaguely remember the change. I don't see the immediate
> connection, but...
Stefan, I think I found an unrelated regression in your commit and I'd
like to double-check with you (or anyone else reading).
modified lisp/textmodes/sgml-mode.el
@@ -395,16 +395,19 @@ sgml--syntax-propertize-ppss
(car (sgml--syntax-propertize-ppss
(match-beginning 0)))))
(string-to-syntax ".")))))
- )))
+ )
+ "Syntax-propertize rules for sgml text.
+These have to be run via `sgml-syntax-propertize'"))
-(defun sgml-syntax-propertize (start end)
+(defconst sgml--syntax-propertize
+ (syntax-propertize-rules sgml-syntax-propertize-rules))
+
+(defun sgml-syntax-propertize (start end &optional rules-function)
"Syntactic keywords for `sgml-mode'."
(setq sgml--syntax-propertize-ppss (cons start (syntax-ppss start)))
(cl-assert (>= (cadr sgml--syntax-propertize-ppss) 0))
(sgml-syntax-propertize-inside end)
- (funcall
- (syntax-propertize-rules sgml-syntax-propertize-rules)
- start end)
+ (funcall (or rules-function sgml--syntax-propertize) (point) end)
;; Catch any '>' after the last quote.
(sgml--syntax-propertize-ppss end))
In the final `funcall`, the `start` argument was changed to `(point)`.
Looking at the overall commit, this seems unintentional to me.
Unless this was intentional, I will upload a patch to fix it (this still
exists in master). Unfortunately, this does not fix the bug I am
interested in, but may as well fix it while I'm here.
next prev parent reply other threads:[~2021-12-24 10:07 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-18 23:52 bug#49629: 27.2; electric-pair-mode doesn't work for angle brackets in HTML file Allen Li
2021-07-22 7:03 ` bug#49629: Acknowledgement (27.2; electric-pair-mode doesn't work for angle brackets in HTML file) Allen Li
2021-07-22 23:34 ` bug#49629: 27.2; electric-pair-mode doesn't work for angle brackets in HTML file Lars Ingebrigtsen
2021-07-25 10:08 ` Allen Li
2021-07-28 15:42 ` Lars Ingebrigtsen
2021-08-01 5:06 ` Allen Li
2021-08-01 10:41 ` Lars Ingebrigtsen
2021-12-09 10:31 ` Allen Li
2021-12-09 13:30 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-24 10:07 ` Allen Li [this message]
2021-12-24 14:23 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-26 8:41 ` Allen Li
2022-06-26 9:38 ` Allen Li
2022-06-26 12:17 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-27 0:33 ` Allen Li
2022-06-27 12:39 ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-02 10:48 ` Allen Li
2022-07-03 10:32 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=80zgoq48p1.fsf@felesatra.moe \
--to=darkfeline@felesatra.moe \
--cc=49629@debbugs.gnu.org \
--cc=larsi@gnus.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).