[Top][All Lists]

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

Re: [Nano-devel] [PATCH] syntax: perl: don't color the character after a

From: Benno Schulenberg
Subject: Re: [Nano-devel] [PATCH] syntax: perl: don't color the character after a variable name
Date: Sun, 11 Aug 2019 19:37:49 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0

Op 11-08-19 om 07:11 schreef Brand Huntsman:
> On Sat, 10 Aug 2019 13:44:42 +0200 Benno Schulenberg <address@hidden>
> wrote:
>> But it will probably be cheaper to replace the "\$?" in the first two 
>> regexes with a "|&$" at the end of the third regex.
> I don't understand how that would handle &$... cases.

The first regex handles the "$..." part; an added |&$ to the third regex
would color also the leading "&".

> If it was possible, I'd rather nothing to the left of the right-most sigil was
> highlighted

I agree: it makes the leading sigil stand out, making it really clear
that there are two sigils.

Vim does does highlight any of "@$ @@ @% @&  %$ %@ %% %&  &$ &@ &% &&",
so I think we can let also nano highlight only $<punct> and not @<punct>
nor %<punct> nor &<punct>.  See the updated upcoming fifth version of
the patch.  This "miscolors" $$var, because it colors both sigils, which
is inconsistent.  But it's either that, or not color $$.


Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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