From 4d509b709a8d855bfbf142f39612acb77d9f9b24 Mon Sep 17 00:00:00 2001 From: rhysd Date: Fri, 17 Jun 2022 22:08:22 +0900 Subject: [PATCH] Highlight `$(...)?` correctly --- syntax/rust.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/syntax/rust.vim b/syntax/rust.vim index 8407b56e..ec4ffff9 100644 --- a/syntax/rust.vim +++ b/syntax/rust.vim @@ -67,7 +67,7 @@ syn keyword rustObsoleteExternMod mod contained nextgroup=rustIdentifier skipw syn match rustIdentifier contains=rustIdentifierPrime "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained syn match rustFuncName "\%(r#\)\=\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained -syn region rustMacroRepeat matchgroup=rustMacroRepeatDelimiters start="$(" end="),\=[*+]" contains=TOP +syn region rustMacroRepeat matchgroup=rustMacroRepeatDelimiters start="$(" end=")\%(,\=[*+]\|?\)" contains=TOP syn match rustMacroVariable "$\w\+" syn match rustRawIdent "\