GNU bug report logs - #33887
26.1; Emacs hangs for several seconds when going to the end of an XML file in nXML mode

Previous Next

Package: emacs;

Reported by: Vincent Lefevre <vincent <at> vinc17.net>

Date: Thu, 27 Dec 2018 10:14:02 UTC

Severity: normal

Tags: fixed

Merged with 25176

Found in versions 26.0.50, 26.1

Fixed in version 27.1

Done: Noam Postavsky <npostavs <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Noam Postavsky <npostavs <at> gmail.com>
To: Vincent Lefevre <vincent <at> vinc17.net>
Cc: Stefan Monnier <monnier <at> iro.umontreal.ca>, 33887 <at> debbugs.gnu.org
Subject: bug#33887: 26.1; Emacs hangs for several seconds when going to the end of an XML file in nXML mode
Date: Mon, 27 May 2019 08:02:18 -0400
[Message part 1 (text/plain, inline)]
Vincent Lefevre <vincent <at> vinc17.net> writes:

> On 2019-05-26 18:17:55 -0400, Noam Postavsky wrote:
>> And about the highlighting of quoted text outside tags, we can just
>> disable fontification, while leaving the syntax code untouched:
> [...]
>
> I've applied it with a minor change against Emacs 26 (context lines
> for hunk #1 of sgml-mode.el are different), but the comments are
> no longer highlighted as comments.

Ah, I guess reusing the default font-lock-syntactic-face-function
doesn't really make sense after all.  So sgml-font-lock-syntactic-face
should be like this:

    (defun sgml-font-lock-syntactic-face (state)
      "`font-lock-syntactic-face-function' for `sgml-mode'."
      ;; Don't use string face outside of tags.
      (cond ((and (nth 9 state) (nth 3 state)) font-lock-string-face)
            ((nth 4 state) font-lock-comment-face)))

[0001-Don-t-fontify-text-outside-of-SGML-XML-tags-Bug-3388.patch (text/plain, attachment)]

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

Previous Next


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