mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 20:36:50 +03:00
Ticket #4319: fix SPICE syntax file to recognize where control script context ends
Since .endc was defined both as the context end delimiter and a context keyword, it was not recognized as the former and the control script context, once started, would never be finished. This issue can be noticed, for example, in wrong syntax highlighting of the .end command if it was preceded by a control script. Fix the issue by making the control script context exclusive and highlighting the .control and .endc keywords in the default context instead. Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
52d9d7946f
commit
d5481d2684
@ -9,12 +9,14 @@ context default
|
||||
|
||||
# dot commands
|
||||
keyword whole .ac brightmagenta
|
||||
keyword whole .control brightmagenta
|
||||
keyword whole .csparam brightmagenta
|
||||
keyword whole .dc brightmagenta
|
||||
keyword whole .disto brightmagenta
|
||||
keyword whole .else brightmagenta
|
||||
keyword whole .elseif brightmagenta
|
||||
keyword whole .end brightmagenta
|
||||
keyword whole .endc brightmagenta
|
||||
keyword whole .endif brightmagenta
|
||||
keyword whole .ends brightmagenta
|
||||
keyword whole .four brightmagenta
|
||||
@ -186,16 +188,13 @@ context default
|
||||
|
||||
context " " green
|
||||
|
||||
context .control .endc
|
||||
context exclusive .control .endc
|
||||
keyword linestart \**\n brown
|
||||
keyword $*\n brown
|
||||
keyword ;*\n brown
|
||||
keyword //*\n brown
|
||||
keyword linestart \+ red
|
||||
|
||||
keyword .control brightmagenta
|
||||
keyword .endc brightmagenta
|
||||
|
||||
# commands
|
||||
keyword whole ac yellow
|
||||
keyword whole alias yellow
|
||||
|
Loading…
Reference in New Issue
Block a user