mcedit: fixed syntax highlighting bug in .c and .cxx syntax scripts

To reproduce, open this .c file in mcedit (remove backslashes):

/* this preprocessor macro is not colorized,
   when there is whitespace before '#' and the next line is not empty */
\  #if not_colorized
int code;

/* this preprocessor macro is colorized properly, the next line is empty */
\  #if colorized

int code2;

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
Sergii Pylypenko 2019-02-07 20:34:46 +02:00 committed by Andrew Borodin
parent 49493dc8e0
commit deceefab74
2 changed files with 2 additions and 2 deletions

View File

@ -36,7 +36,7 @@ context default
keyword whole inline yellow
keyword whole wchar_t yellow
keyword whole ... yellow
keyword whole linestart \{\s\t\}\[\s\t\]#*\n brightmagenta
keyword linestart \{\s\t\}\[\s\t\]#*\n brightmagenta
keyword whole \[\s\t\]default yellow
keyword whole linestart \[\s\t\]\{ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz\}\[0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz\]: cyan

View File

@ -62,7 +62,7 @@ context default
keyword whole using yellow
keyword whole wchar_t yellow
keyword whole ... yellow
keyword whole linestart \{\s\t\}\[\s\t\]#*\n brightmagenta
keyword linestart \{\s\t\}\[\s\t\]#*\n brightmagenta
keyword /\* brown
keyword \*/ brown