mirror of
git://git.sv.gnu.org/nano.git
synced 2024-12-30 22:24:41 +03:00
syntax: perl: avoid upsetting older glibcs with crafty range expression
The regcomp() function from glibc-2.27 (and older) considers the bracket expression ['-.] to be invalid -- mistakenly. Avoid using any range expression in the relevant regex and instead enumerate all acceptable characters. This avoids https://savannah.gnu.org/bugs/?56766.
This commit is contained in:
parent
5c399dfc6e
commit
bdf1a9d4e7
@ -11,7 +11,7 @@ color magenta "\<(continue|else|elsif|do|for|foreach|if|unless|until|while|eq|ne
|
||||
# Variable names.
|
||||
color cyan "[$%&@]([A-Za-z_][0-9A-Za-z_]*|\^[][A-Z?\^_]|[0-9]+)\>"
|
||||
color cyan "[$%&@]\{(\^?[A-Za-z_][0-9A-Za-z_]*|\^[][?\^][0-9]+)\}"
|
||||
color cyan "[$%&@]([][!"#'-.:-?`|~]|\{[][!-/:-@\`|~]\})|\$[$%&@]"
|
||||
color cyan "[$%&@]([][!"#'()*+,.:;<=>?`|~-]|\{[][!-/:-@\`|~]\})|\$[$%&@]"
|
||||
color cyan "(^|[[:space:]])[$%@][/\]"
|
||||
|
||||
color yellow "".*"|qq\|.*\|"
|
||||
|
Loading…
Reference in New Issue
Block a user