GNU bug report logs - #27391
25.2.50; utf-8 coding cookie is not applied on some specific markdown file

Previous Next

Package: emacs;

Reported by: vincent.belaiche <at> gmail.com (Vincent Belaïche)

Date: Fri, 16 Jun 2017 10:01:01 UTC

Severity: normal

Found in version 25.2.50

Done: Philipp Stephani <p.stephani2 <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Vincent Belaïche <vincent.belaiche <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 27391 <at> debbugs.gnu.org
Subject: Re: bug#27391: 25.2.50; utf-8 coding cookie is not applied on some
 specific markdown file
Date: Fri, 16 Jun 2017 21:37:37 +0200

Le 16/06/2017 à 21:15, Vincent Belaïche a écrit :
>
>
> Le 16/06/2017 à 20:38, Eli Zaretskii a écrit :
>>> From: vincent.belaiche <at> gmail.com (Vincent Belaïche)
>>> Cc: Vincent Belaïche <vincent.belaiche <at> gmail.com>
>>> Date: Fri, 16 Jun 2017 16:08:09 +0200
>>>
>>> Attached is the file causing the issue. Recipe is just to visit the 
>>> file
>>> with emacs -q, and you see that the encoding is not taken.
>> Your fancy comment causes this: remove the leading '[' and the problem
>> goes away.  Looks like regex-quoting that somehow misfires.
>
> After some investigation, it seems that the bug is in regexp-quote:
>
> (regexp-quote "[comment]: # (")
>
> outputs
>
> "^\\[comment]: # ( "
>
> instead of
>
> "^\\[comment\\]: # ( "
>
>
>   Vincent.
>
>
After some more investigation, I think that the bug is in function
insert-file-contents of fileio.c which is the one that decide and sets
the coding system well before the other local variables are looked into.

---
L'absence de virus dans ce courrier électronique a été vérifiée par le logiciel antivirus Avast.
https://www.avast.com/antivirus





This bug report was last modified 8 years and 24 days ago.

Previous Next


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