tweaks: fold a few pairs of regexes into each other

master
Benno Schulenberg 2018-11-03 21:20:06 +01:00
parent 636e9ac3e8
commit 02eaa4ce6d
4 changed files with 4 additions and 8 deletions

View File

@ -19,8 +19,7 @@ color green "(\{|\}|\(|\)|\;|\]|\[|\\|<|>|!|=|&|\+|-|\*|%|/|\?:|\^|\|)"
color brightyellow "\<(for|if|while|do|else|in|delete|exit)\>"
color brightyellow "\<(break|continue|return)\>"
# I/O statements.
color brightgreen "\<(close|getline|next|nextfile|print|printf)\>"
color brightgreen "\<(system|fflush)\>"
color brightgreen "\<(close|fflush|getline|next|nextfile|print|printf|system)\>"
# Standard functions.
color magenta "\<(atan2|cos|exp|int|log|rand|sin|sqrt|srand)\>"
color magenta "\<(asort|asorti|gensub|gsub|index|length|match)\>"

View File

@ -15,6 +15,5 @@ icolor brightred "^[[:space:]]*((end)?(function|macro)|return)"
icolor cyan start="\$(\{|ENV\{)" end="\}"
color magenta "\<(APPLE|UNIX|WIN32|CYGWIN|BORLAND|MINGW|MSVC(_IDE|60|71|80|90)?)\>"
icolor brightblue "^([[:space:]]*)?#.*"
icolor brightblue "[[:space:]]#.*"
color brightblue "(^|[[:space:]])#.*"
color ,green "[[:space:]]+$"

View File

@ -5,6 +5,5 @@ header "^%include.*"
comment "#"
icolor green "^%[a-z].*"
color cyan "(^|[[:space:]])#.*"
color cyan "(^|[[:space:]])%%.*"
color cyan "(^|[[:space:]])(#|%%).*"
color ,green "[[:space:]]+$"

View File

@ -59,9 +59,8 @@ color green "'([^']|(\\'))*'" "%[qw]\{[^}]*\}" "%[qw]\([^)]*\)" "%[qw]<[^>]*>"
color green "%[qw]\[[^]]*\]" "%[qw]\$[^$]*\$" "%[qw]\^[^^]*\^" "%[qw]![^!]*!"
# Comments.
color red "#[^{].*" "#$"
color red "##?[^{].*" "##?$"
color red "--[^{].*" "--$"
color red "##[^{].*" "##$"
color brightblue "//.*"
color brightblue start="/\*" end="\*/"