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:
Benno Schulenberg 2019-08-19 17:00:11 +02:00
parent 5c399dfc6e
commit bdf1a9d4e7
1 changed files with 1 additions and 1 deletions

View File

@ -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\|.*\|"