GNU bug report logs - #69604
perl mode: quotes give wrong colors

Previous Next

Package: emacs;

Reported by: Dan Jacobson <jidanni <at> jidanni.org>

Date: Thu, 7 Mar 2024 08:54:02 UTC

Severity: normal

Done: Harald Jörg <haj <at> posteo.de>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Harald Jörg <haj <at> posteo.de>
To: 69604 <at> debbugs.gnu.org
Subject: bug#69604: perl-mode and cperl-mode: $\" in a double-quoted string
Date: Fri, 08 Mar 2024 07:25:45 +0000
Good catch!  The same symptoms can be seen in cperl-mode.

Both perl-mode and cperl-mode treat "$" as quoting character in their
syntax tables.  This is needed for Perl's punctuation variables like $(
and $" which would otherwise be interpreted as unbalanced parens or
quotes.

In a string, this safety belt is not required, and it actually misfires
in the case of "$\"", which is part of the demo code.

This is now treated correctly in the Emacs master branch for both
perl-mode and cperl-mode.




This bug report was last modified 1 year and 78 days ago.

Previous Next


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