GNU bug report logs - #73206
28.2; xml comment with blank lines to do not indent correctly, nxml-mode.el

Previous Next

Package: emacs;

Reported by: ciolfi <at> mathworks.com

Date: Thu, 12 Sep 2024 18:04:03 UTC

Severity: normal

Found in version 28.2

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


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

From: Stefan Kangas <stefankangas <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>, John Ciolfi <ciolfi <at> mathworks.com>
Cc: 73206 <at> debbugs.gnu.org, rpluim <at> gmail.com
Subject: Re: bug#73206: 28.2; xml comment with blank lines to do not indent
 correctly, nxml-mode.el
Date: Sun, 29 Sep 2024 13:47:44 -0700
Eli Zaretskii <eliz <at> gnu.org> writes:

> Stefan, does the patch with the regexp fix look correct to you?

If we want to "keep going back until we see a non-blank line", surely
the fragment should read:

    (while (looking-at "^$")
      (forward-line -1))

Since

    (looking-at "^[[:blank:]]*$")

will match both blank lines, and lines containing only blank space.

Which of the two do we want here?

I think it would also be good to add one or more tests here.




This bug report was last modified 11 days ago.

Previous Next


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