Subject: bug#23461: perl-mode: Displaying HERE-docs as strings instead of comments [PATCH]

From: [email-masked] (Harald Jörg)
Date: Tue, 05 Jan 2021 13:30:36 +0100

Lars Ingebrigtsen <[email-masked]> writes:

> [email-masked] (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