bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#23461: perl-mode: Displaying HERE-docs as strings instead of comment


From: Harald Jörg
Subject: bug#23461: perl-mode: Displaying HERE-docs as strings instead of comments [PATCH]
Date: Tue, 05 Jan 2021 13:30:36 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux)

Lars Ingebrigtsen <larsi@gnus.org> writes:

> haj@posteo.de (Harald Jörg) writes:
>
>> The trick: The lone "#" is now syntaxified as "whitespace" and
>> font-lock-faced as comment.  This is ugly, but also well-contained in
>> the offending line, so should not have unwanted effects at a distance.
>>
>> The tests are designed for, and pass, for both Perl mode and CPerl mode.
>
> Thanks; applied to Emacs 28.  However, the cperl tests failed -- I stuck
> a (require 'perl-mode) into the test, and that made it work.  I don't
> know whether that's the proper solution here, though -- please have a look.

Ouch - and thanks!

Adding (require 'perl-mode) is the correct thing to do.  In my batch
tests I loaded it explicitly for no good reason, I've eliminated that
now.

The tests need both modes to account for different names of custom
variables (here: cperl-continued-statement-offset
vs. perl-continued-statement-offset) which affect the expected outcome.
-- 
Thanks again,
haj






reply via email to

[Prev in Thread] Current Thread [Next in Thread]