mirror of
git://git.sv.gnu.org/nano.git
synced 2024-11-25 22:29:42 +03:00
syntax: c: colorize also labels that contain digits, and uncolorize colon
Labels may contain digits (after the first character). And the colon after "default" should not be colored. Inspired-by: Hussam al-Homsi <sawuare@gmail.com>
This commit is contained in:
parent
ede64d7ea0
commit
3d9e803aed
@ -8,7 +8,8 @@ comment "//"
|
||||
# Constants.
|
||||
color brightred "\<[A-Z_][0-9A-Z_]*\>"
|
||||
# Labels.
|
||||
color brightmagenta "^[[:space:]]*[A-Z_a-z]+:[[:space:]]*$"
|
||||
color brightmagenta "^\s*[A-Z_a-z][0-9A-Z_a-z]*:\s*$"
|
||||
color normal ":\s*$"
|
||||
|
||||
# Types and related keywords.
|
||||
color green "\<(auto|bool|char|const|double|enum|extern|float|inline|int|long|restrict|short|signed|sizeof|static|struct|typedef|union|unsigned|void)\>"
|
||||
|
Loading…
Reference in New Issue
Block a user