diff options
-rw-r--r-- | mu.vim | 12 | ||||
-rw-r--r-- | vimrc.vim | 3 |
2 files changed, 8 insertions, 7 deletions
diff --git a/mu.vim b/mu.vim index a90e2bec..2a033b35 100644 --- a/mu.vim +++ b/mu.vim @@ -39,15 +39,17 @@ highlight link muString String syntax region muScreen start=+ \.+ end=+\.$\|$+ highlight link muScreen muString -" all mu literals are constants +" mu literals syntax match muNumber %[^ ]\+:literal/\?[^ ,]*% highlight link muNumber Constant +syntax match muLabel "^\s\+[^ 0-9a-zA-Z{}\[\]][^ ]*\s*$" +syntax match muLabel %[^ ]\+:label/\?[^ ,]*% +highlight link muLabel Constant +syntax keyword muKeyword default-space next-ingredient ingredient | highlight link muKeyword Constant syntax match muDelimiter "[{}]" | highlight link muDelimiter Delimiter -syntax match muLabel " [^a-zA-Z0-9 \[\.][a-zA-Z0-9-]\+" | highlight link muLabel Function -syntax match muAssign " <- " | highlight link muAssign SpecialChar -syntax match muAssign "\<raw\>" -syntax keyword muControl reply reply-if reply-unless jump jump-if jump-unless loop loop-if loop-unless break-if break-unless default-space next-ingredient ingredient current-continuation continue-from create-delimited-continuation reply-delimited-continuation | highlight link muControl Function +syntax match muAssign " <- \|\<raw\>" | highlight link muAssign SpecialChar +syntax keyword muControl reply reply-if reply-unless jump jump-if jump-unless loop loop-if loop-unless break-if break-unless current-continuation continue-from create-delimited-continuation reply-delimited-continuation | highlight muControl ctermfg=3 " common keywords syntax keyword muRecipe recipe before after | highlight muRecipe ctermfg=208 syntax keyword muScenario scenario | highlight muScenario ctermfg=34 diff --git a/vimrc.vim b/vimrc.vim index 34fbbb9d..a3f31d1e 100644 --- a/vimrc.vim +++ b/vimrc.vim @@ -24,8 +24,7 @@ function! HighlightTangledFile() syntax match muCommentedCode /#? .*$/ | highlight link muCommentedCode CommentedCode set comments+=n:# " Some other bare-bones mu highlighting. - syntax match muAssign " <- " | highlight link muAssign SpecialChar - syntax match muAssign "\<raw\>" + syntax match muAssign " <- \|\<raw\>" | highlight link muAssign SpecialChar endfunction call HighlightTangledFile() autocmd BufRead,BufNewFile *.mu set ft=mu |