GNU bug report logs - #20800
perl mode reads into comments too deeply

Previous Next

Package: emacs;

Reported by: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>

Date: Sat, 13 Jun 2015 06:24:02 UTC

Severity: minor

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#20800: closed (perl mode reads into comments too deeply)
Date: Tue, 16 Jun 2015 01:04:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Mon, 15 Jun 2015 21:03:31 -0400
with message-id <jwvlhfljgw2.fsf-monnier+emacsbugs <at> gnu.org>
and subject line Re: bug#20800: perl mode reads into comments too deeply
has caused the debbugs.gnu.org bug report #20800,
regarding perl mode reads into comments too deeply
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
20800: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=20800
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
To: bug-gnu-emacs <bug-gnu-emacs <at> gnu.org>
Subject: perl mode reads into comments too deeply
Date: Sat, 13 Jun 2015 14:23:34 +0800
For this snippet of code perl mode gets the colors wrong:

return 'W' if               #/^Not Available on Mobile/m;    #W=Web only
    /This video is not available on mobile devices./m;
#After the m all is the wrong color.


[Message part 3 (message/rfc822, inline)]
From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: 積丹尼 Dan Jacobson <jidanni <at> jidanni.org>
Cc: 20800-done <at> debbugs.gnu.org
Subject: Re: bug#20800: perl mode reads into comments too deeply
Date: Mon, 15 Jun 2015 21:03:31 -0400
> For this snippet of code perl mode gets the colors wrong:
> return 'W' if               #/^Not Available on Mobile/m;    #W=Web only
>     /This video is not available on mobile devices./m;
> #After the m all is the wrong color.

Indeed, the code did not handle the case of a comment between the "if"
and the "/": it treated this slash as a division operator.
I installed a patch into the "master" branch which should fix it,


        Stefan


This bug report was last modified 10 years and 19 days ago.

Previous Next


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