diff --git a/syntax/nomsu.vim b/syntax/nomsu.vim index f1bc255..071aa10 100644 --- a/syntax/nomsu.vim +++ b/syntax/nomsu.vim @@ -21,7 +21,7 @@ hi def link nomsuOneLineComment Comment syn region nomsuComment start=/#\.\.[^\n]*$\n\(\s*\n\)*\z(\s\+\)\S/ skip=/^\%(\z1\S\|^\s*$\)/ end=/^\z1\@!.*/me=s-1 hi def link nomsuComment Comment -syn region nomsuString1 start=/"/ skip=/\\\\\|\\"/ end=/"/ +syn region nomsuString1 start=/"\(\.\."\)\@!/ skip=/\\\\\|\\"/ end=/"/ hi def link nomsuString1 String syn match nomsuStringLineStart /\(^[ \t]*\|"\.\."\s*\)\@<=|/ contained @@ -30,11 +30,8 @@ syn match nomsuStringTrailingSpace /[ \t]*$/ contained hi nomsuStringTrailingSpace ctermbg=Magenta -syn region nomsuLongString2 start=/"\.\."\s*|/ end=/$/ -\ contains=nomsuInterp,nomsuStringLineStart,nomsuStringTrailingSpace -hi def link nomsuLongString2 String -syn region nomsuLongString start=/"\.\.".*$\n\(\s*\n\)*\z(\s\+\)\S/ skip=/^\%(\z1\S\|^\s*$\)/ end=/^\z1\@!.*/me=s-1 -\ contains=nomsuInterp,nomsuStringLineStart,nomsuStringTrailingSpace +syn region nomsuLongString start=/\(^\z(\s*\)\S.*\)\@<="\.\."/ skip=/^\(\z1\s\|\s*$\)/ end=/\n\(\z1\s\)\@!/me=s-1 +\ contains=nomsuInterp,nomsuStringLineStart,nomsuStringTrailingSpace,nomsuOneLineComment,nomsuComment hi def link nomsuLongString String syn match nomsuVar /\v\%[a-zA-Z0-9_'+*/^&$@#-]*/ @@ -62,7 +59,7 @@ hi def link nomsuThunk Structure syn match nomsuToken /\v(\%)@