nano-devel
[Top][All Lists]
Advanced

[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: Brand Huntsman
Subject: Re: [Nano-devel] [PATCH] syntax: perl: don't color the character after a variable name
Date: Tue, 6 Aug 2019 14:55:51 -0600

On Tue, 6 Aug 2019 20:09:25 +0200
Benno Schulenberg <address@hidden> wrote:

> > "[$@%&*]\$?(\^[][A-Z^_?\]|[0-9]+|[A-Za-z_][0-9A-Za-z_]*|[][`~!@#$%&*-=+;:'",.\\|/?()<>])|\{(\^_?[0-9A-Za-z]+|[0-9]+|[A-Za-z_][0-9A-Za-z_]*)\})"
> >   
> 
> What do the & and * sigils do?

They help to make perl harder to read. :)

They're apparently sigils like the other three and also valid before $ sigil 
variables.


> Why is the "\$?" there?

The 5 sigils are valid before $ as a double sigil. As far as I can tell, they 
are only valid before $ and not before each other. I had a second url that I 
forgot to attach and can't find again.

    foreach my $line (@$out) {

Without the \$?, only the @$ is highlighted in that line.


> The "*-=" fragment is a range that includes all digits.  When "-"
> should be taken literally, it needs to be first or last in the set.
> But instead of enumerating all possible characters, I would use a
> few short ranges: "[][!-/:-?\`|~]".

Yes, that minus should have been at the end, it wasn't intended to be a range.




reply via email to

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