diff options
author | Jonas Smedegaard <dr@jones.dk> | 2020-04-14 11:04:32 +0200 |
---|---|---|
committer | Jonas Smedegaard <dr@jones.dk> | 2020-04-14 11:04:32 +0200 |
commit | fbf8e63e28493a6a7e7bebb9f37630469f033289 (patch) | |
tree | 4300a9fd0e706542a3eb9b85b39a4b3548a089a0 /mc/syntax | |
parent | 9d4664201717049c2acddff677a8d165cdd8126a (diff) |
match single-line literals after multi-line literals and comments
Diffstat (limited to 'mc/syntax')
-rw-r--r-- | mc/syntax/turtle.syntax | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/mc/syntax/turtle.syntax b/mc/syntax/turtle.syntax index 6d28f87..3832ad7 100644 --- a/mc/syntax/turtle.syntax +++ b/mc/syntax/turtle.syntax @@ -88,19 +88,6 @@ context < > brightred keyword \\U\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\} brightgreen keyword \\\{tnr>\\} brightgreen -# Single-line literals -context " " green - spellcheck - -# TODO: enable when context ending at newline doesn't ruin next context -# syntax violation -# keyword +\n black red - -# String escape - keyword \\u\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\} brightgreen - keyword \\U\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\} brightgreen - keyword \\\{tnr"\\} brightgreen - # Multi-line literals context """ """ green spellcheck @@ -118,3 +105,16 @@ context linestart # \n brown # but contexts can't start with a character class. So we define comments twice. context linestart \s\[\s\]# \n brown spellcheck + +# Single-line literals +context " " green + spellcheck + +# TODO: enable when context ending at newline doesn't ruin next context +# syntax violation +# keyword +\n black red + +# String escape + keyword \\u\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\} brightgreen + keyword \\U\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\}\{0123456789abcdef\} brightgreen + keyword \\\{tnr"\\} brightgreen |