GNU bug report logs - #6267
23.1; invalid XML in nested comments produced by comment-region

Previous Next

Package: emacs;

Reported by: Patrik Hägglund H <patrik.h.hagglund <at> ericsson.com>

Date: Tue, 25 May 2010 12:34:01 UTC

Severity: normal

Found in version 23.1

Fixed in version 25.1

Done: Ivan Andrus <darthandrus <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Ivan Andrus <darthandrus <at> gmail.com>
Cc: 20001 <at> debbugs.gnu.org, 6267 <at> debbugs.gnu.org, patrik.h.hagglund <at> ericsson.com
Subject: Re: bug#6267: 23.1;
 invalid XML in nested comments produced by comment-region
Date: Sat, 19 Sep 2015 00:07:33 -0400
The approach looks fine, thank you.

> +(defvar comment-quote-nested-function #'comment-quote-nested-default
[...]
> +  (when (and comment-quote-nested
> +      comment-quote-nested-function

comment-quote-nested-function will always be a function so it should
never be nil, so there's no need to test it here.

> +The arguments CS and CE are regular expressions matching comment
> +starting and ending delimiters respectively.

AFAICT this is not true.  They're just strings, not regexps.

> +  (make-local-variable 'comment-quote-nested-function)
> +  (setq comment-quote-nested-function 'nxml-comment-quote-nested)

I know the rest of the file doesn't use it, but please in new code use:

     (setq-local comment-quote-nested-function #'nxml-comment-quote-nested)


-- Stefan




This bug report was last modified 9 years and 244 days ago.

Previous Next


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