rust highlighter: '"' is not the start of a string
this uses the string opening regex from the c-family highlighter to prevent highlighting the rest of the file as a string on encountering the character literal '"'
This commit is contained in:
parent
f9c48237a7
commit
3ae0d86b27
|
@ -12,7 +12,7 @@ hook global BufCreate .*[.](rust|rs) %{
|
|||
# ‾‾‾‾‾‾‾‾‾‾‾‾
|
||||
|
||||
add-highlighter -group / regions -default code rust \
|
||||
string '"' (?<!\\)(\\\\)*" '' \
|
||||
string %{(?<!')"} (?<!\\)(\\\\)*" '' \
|
||||
comment // $ '' \
|
||||
comment /\* \*/ /\*
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user