- Add regexes for Bourne shell scripts. (Mike Frysinger, minor
tweaks by DLR)
- Explain how the "none" and "default" syntaxes work. (DLR)
+ - Tweaks and additions to the "c-file" regexes: handle #defined
+ constants more accurately and use a brighter color for them,
+ support more GCC builtins, and color code flow control
+ statements differently. (Mike Frysinger)
- doc/man/nanorc.5:
- Explain how the "none" and "default" syntaxes work. (DLR)
- doc/man/fr/nano.1, doc/man/fr/nanorc.5:
## to set the background color to black or white.
##
# syntax "c-file" "\.(c|C|cc|cpp|cxx|h|H|hh|hpp|hxx)$"
-# color red "\<[A-Z_]{2,}\>"
+# color brightred "\<[A-Z_][A-Z_0-9]+\>"
# color green "\<(float|double|bool|char|int|short|long|sizeof|enum|void|static|const|struct|union|typedef|extern|signed|unsigned|inline)\>"
# color green "\<(class|namespace|template|public|protected|private|typename|this|friend|virtual|using|mutable|volatile|register|explicit)\>"
-# color brightyellow "\<(for|if|while|do|else|case|default|switch|goto|continue|break|return)\>"
+# color brightyellow "\<(for|if|while|do|else|case|default|switch)\>"
# color brightyellow "\<(try|throw|catch|operator|new|delete)\>"
+# color magenta "\<(goto|continue|break|return)\>"
# color brightcyan "^[[:space:]]*#[[:space:]]*(define|undef|include|ifn?def|endif|elif|else|if|warning|error)"
# color brightmagenta "'([^\]|(\\['abfnrtv\\]))'" "'\\(([0-7][0-7]?)|([0-3][0-7][0-7]))'" "'\\x[0-9A-Fa-f][0-9A-Fa-f]?'"
##
## GCC builtins
##
-# color cyan "__attribute__[[:space:]]*\(\([^)]*\)\)" "__(asm|builtin|inline|restrict|typeof)__"
+# color cyan "__attribute__[[:space:]]*\(\([^)]*\)\)" "__(aligned|asm|builtin|hidden|inline|packed|restrict|section|typeof|weak)__"
##
## You will in general want your comments and strings to come last,
## because syntax highlighting rules will be applied in the order they