summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Stankiewicz <sheerun@sher.pl>2022-02-17 04:31:35 +0100
committerAdam Stankiewicz <sheerun@sher.pl>2022-02-17 04:31:45 +0100
commitb77c5f11070ecb2ff343aa18b4ea859e6168f16c (patch)
treec93d347b096ce19556f369428913b697e6aafa00
parent2c5af8f89d3e61e04e761c07a1f043b0f35203c6 (diff)
downloadvim-polyglot-b77c5f11070ecb2ff343aa18b4ea859e6168f16c.tar.gz
vim-polyglot-b77c5f11070ecb2ff343aa18b4ea859e6168f16c.zip
Update
-rw-r--r--README.md4
-rw-r--r--after/syntax/javascript/graphql.vim4
-rw-r--r--after/syntax/typescript/graphql.vim9
-rw-r--r--after/syntax/zsh.vim275
-rw-r--r--autoload/clojurecomplete.vim2
-rw-r--r--autoload/csv.vim6
-rw-r--r--autoload/dart.vim12
-rw-r--r--autoload/freebasic.vim45
-rw-r--r--autoload/fsharp.vim53
-rw-r--r--autoload/polyglot/ft.vim753
-rw-r--r--autoload/polyglot/init.vim6
-rw-r--r--autoload/polyglot/sleuth.vim6
-rw-r--r--autoload/unison.vim12
-rw-r--r--compiler/ocaml.vim8
-rw-r--r--extras/filetype.vim111
-rw-r--r--extras/menu.vim675
-rw-r--r--ftplugin/basic.vim43
-rw-r--r--ftplugin/freebasic.vim60
-rw-r--r--ftplugin/markdown.vim86
-rw-r--r--ftplugin/plantuml.vim1
-rw-r--r--indent/basic.vim15
-rw-r--r--indent/freebasic.vim15
-rw-r--r--indent/glsl.vim2
-rw-r--r--indent/markdown.vim18
-rw-r--r--indent/plantuml.vim3
-rw-r--r--indent/solidity.vim4
-rw-r--r--syntax/basic.vim482
-rw-r--r--syntax/clojure.vim32
-rw-r--r--syntax/crystal.vim6
-rw-r--r--syntax/eelixir.vim2
-rw-r--r--syntax/glsl.vim76
-rw-r--r--syntax/go.vim2
-rw-r--r--syntax/julia.vim2
-rw-r--r--syntax/markdown.vim10
-rw-r--r--syntax/mermaid.vim8
-rw-r--r--syntax/odin.vim5
-rw-r--r--syntax/opam.vim34
-rw-r--r--syntax/plantuml.vim129
-rw-r--r--syntax/rc.vim21
-rw-r--r--syntax/swift.vim5
-rw-r--r--syntax/tmux.vim27
-rw-r--r--syntax/zig.vim3
42 files changed, 1870 insertions, 1202 deletions
diff --git a/README.md b/README.md
index a33ce80f..0b582223 100644
--- a/README.md
+++ b/README.md
@@ -177,7 +177,7 @@ On top of all language packs from [vim repository](https://github.com/vim/vim/tr
- [rust](https://github.com/rust-lang/rust.vim) (Rust syntax highlighting for rs and rs.in files)
- [scala](https://github.com/derekwyatt/vim-scala) (Scala syntax highlighting for scala, kojo and sc files)
- [scss](https://github.com/cakebaker/scss-syntax.vim) (SCSS syntax highlighting for scss files)
-- [sh](https://github.com/arzg/vim-sh) (Shell syntax highlighting for sh, bash, bats, cgi, command and 7 more files)
+- [sh](https://github.com/arzg/vim-sh) (Shell syntax highlighting for sh, bash, bats, cgi, command and 8 more files)
- [slim](https://github.com/slim-template/vim-slim) (Slim syntax highlighting for slim files)
- [slime](https://github.com/slime-lang/vim-slime-syntax) (Syntax highlighting for slime files)
- [smt2](https://github.com/bohlender/vim-smt2) (SMT syntax highlighting for smt2 and smt files)
@@ -206,7 +206,7 @@ On top of all language packs from [vim repository](https://github.com/vim/vim/tr
- [velocity](https://github.com/lepture/vim-velocity) (Syntax highlighting for vm files)
- [vue](https://github.com/posva/vim-vue) (Vue syntax highlighting for vue and wpy files)
- [xdc](https://github.com/amal-khailtash/vim-xdc-syntax) (Syntax highlighting for xdc files)
-- [xml](https://github.com/amadeus/vim-xml) (XML syntax highlighting for xml, adml, admx, ant, axml and 95 more files)
+- [xml](https://github.com/amadeus/vim-xml) (XML syntax highlighting for xml, adml, admx, ant, axaml and 96 more files)
- [xsl](https://github.com/vim-scripts/XSLT-syntax) (XSLT syntax highlighting for xslt and xsl files)
- [yard](https://github.com/noprompt/vim-yardoc)
- [zephir](https://github.com/xwsoul/vim-zephir) (Zephir syntax highlighting for zep files)
diff --git a/after/syntax/javascript/graphql.vim b/after/syntax/javascript/graphql.vim
index f76f0fab..459f79f7 100644
--- a/after/syntax/javascript/graphql.vim
+++ b/after/syntax/javascript/graphql.vim
@@ -46,7 +46,7 @@ if graphql#has_syntax_group('jsTemplateExpression')
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=jsTemplateExpression containedin=graphqlFold keepend
- syntax region graphqlTemplateString matchgroup=jsTemplateString start=+`#\s\{,4\}gql\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend
+ syntax region graphqlTemplateString matchgroup=jsTemplateString start=+`#\s\{,4\}\(gql\|graphql\)\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend
hi def link graphqlTemplateString jsTemplateString
hi def link graphqlTaggedTemplate jsTaggedTemplate
@@ -60,7 +60,7 @@ elseif graphql#has_syntax_group('javaScriptStringT')
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=@javaScriptEmbededExpr containedin=graphqlFold keepend
- syntax region graphqlTemplateString matchgroup=javaScriptStringT start=+`#\s\{,4\}gql\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend
+ syntax region graphqlTemplateString matchgroup=javaScriptStringT start=+`#\s\{,4\}\(gql\|graphql\)\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend
hi def link graphqlTemplateString javaScriptStringT
hi def link graphqlTaggedTemplate javaScriptEmbed
diff --git a/after/syntax/typescript/graphql.vim b/after/syntax/typescript/graphql.vim
index 95055006..1363f7a5 100644
--- a/after/syntax/typescript/graphql.vim
+++ b/after/syntax/typescript/graphql.vim
@@ -46,6 +46,15 @@ exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlT
" Support expression interpolation ((${...})) inside template strings.
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=typescriptTemplateSubstitution containedin=graphqlFold keepend
+" support #graphql , #gql comment strings
+syntax region graphqlTemplateString
+ \ start=+`\(#\s\{,4\}\(gql\|graphql\)\)\@=+
+ \ skip=+\\\\\|\\`+
+ \ end=+`+me=s-1
+ \ containedin=typescriptTemplate
+ \ contained
+ \ contains=@GraphQLSyntax,typescriptTemplateSubstitution extend
+
hi def link graphqlTemplateString typescriptTemplate
hi def link graphqlTemplateExpression typescriptTemplateSubstitution
diff --git a/after/syntax/zsh.vim b/after/syntax/zsh.vim
index cf4f9246..118345c4 100644
--- a/after/syntax/zsh.vim
+++ b/after/syntax/zsh.vim
@@ -3,6 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'zinit', 'after/syntax/zsh.vim
endif
" Copyright (c) 2019 Sebastian Gniazdowski
+" Copyright (c) 2021 Joakim Gottzén
"
" Syntax highlighting for Zinit commands in any file of type `zsh'.
" It adds definitions for the Zinit syntax to the ones from the
@@ -10,117 +11,163 @@ endif
" Main Zinit command.
" Should be the only TOP rule for the whole syntax.
-syntax match ZinitCommand /\<zinit\>\s/me=e-1
- \ skipwhite
- \ nextgroup=ZinitSubCommands,ZinitPluginSubCommands,ZinitSnippetSubCommands
- \ contains=ZinitSubCommands,ZinitPluginSubCommands,ZinitSnippetSubCommands
-
-" TODO: add options for e.g. light
-syntax match ZinitSubCommands /\s\<\%(ice\|compinit\|env-whitelist\|cdreplay\|cdclear\|update\)\>\s/ms=s+1,me=e-1
- \ contained
-
-syntax match ZinitPluginSubCommands /\s\<\%(light\|load\)\>\s/ms=s+1,me=e-1
- \ skipwhite nextgroup=ZinitPlugin1,ZinitPlugin2,ZinitPlugin3
- \ contains=ZinitPlugin1,ZinitPlugin2,ZinitPlugin3
-
-syntax match ZinitSnippetSubCommands /\s\<\%(snippet\)\>\s/ms=s+1,me=e-1
- \ skipwhite
- \ nextgroup=ZinitSnippetShorthands1,ZinitSnippetShorthands2
- \ contains=ZinitSnippetShorthands1,ZinitSnippetShorthands2
-
-" "user/plugin"
-syntax match ZinitPlugin1 /\s["]\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)["]/ms=s+1,hs=s+2,he=e-1
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" 'user/plugin'
-syntax match ZinitPlugin2 /\s[']\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)[']/ms=s+1,hs=s+2,he=e-1
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" user/plugin
-syntax match ZinitPlugin3 /\s\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)/ms=s+1,me=e+2
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" OMZ:: or PZT::
-" TODO: 'OMZ:: or 'PZT::
-syntax match ZinitSnippetShorthands1 /\s\<\%(\%(OMZ\|PZT\)\>::\|\)/hs=s+1,he=e-2
- \ contained
- \ skipwhite
- \ nextgroup=ZinitSnippetUrl1,ZinitSnippetUrl2
- \ contains=ZinitSnippetUrl1,ZinitSnippetUrl2
-
-" "OMZ:: or "PZT::
-syntax match ZinitSnippetShorthands2 /\s["]\%(\%(OMZ\|PZT\)\>::\|\)/hs=s+2,he=e-2
- \ contained
- \ skipwhite
- \ nextgroup=ZinitSnippetUrl3,ZinitSnippetUrl4
- \ contains=ZinitSnippetUrl3,ZinitSnippetUrl4
-
-syntax match ZinitSnippetUrl3 /\<\%(http:\/\/\|https:\/\/\|ftp:\/\/\|\$HOME\|\/\)[!-_]\+\%(\/[!-_]\+\)*\/\?["]/he=e-1
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" TODO: Fix ZinitTrailingWhiteSpace not matching
-syntax match ZinitSnippetUrl4 /\%(\%(OMZ\|PZT\)::\)[!-_]\+\%(\/[!-_]\+\)*\/\?["]/hs=s+5,he=e-1
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" http://… or https://… or ftp://… or $HOME/… or /…
-" TODO: Fix $HOME/… and /… not matching
-syntax match ZinitSnippetUrl1 /\<\%(http:\/\/\|https:\/\/\|ftp:\/\/\|\$HOME\|\/\)[!-_]\+\%(\/[!-_]\+\)*\/\?/
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-" TODO: Fix ZinitTrailingWhiteSpace not matching
-syntax match ZinitSnippetUrl2 /\<\%(\%(OMZ\|PZT\)::\)[!-_]\+\%(\/[!-_]\+\)*\/\?/hs=s+5
- \ contained
- \ nextgroup=ZinitTrailingWhiteSpace
- \ contains=ZinitTrailingWhiteSpace
-
-syntax match ZinitTrailingWhiteSpace /[[:space:]]\+$/ contained
-
-" TODO: differentiate the no-value ices
-" TODO: use contained
-syntax match ZinitIceSubCommand /\sice\s/ms=s+1,me=e-1 nextgroup=ZinitIceModifiers
-syntax match ZinitIceModifiers /\s\<\%(svn\|proto\|from\|teleid\|bindmap\|cloneopts\|id-as\|depth\|if\|wait\|load\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(unload\|blockf\|on-update-of\|subscribe\|pick\|bpick\|src\|as\|ver\|silent\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(lucid\|notify\|mv\|cp\|atinit\|atclone\|atload\|atpull\|nocd\|run-atpull\|has\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(cloneonly\|make\|service\|trackbinds\|multisrc\|compile\|nocompile\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(nocompletions\|reset-prompt\|wrap-track\|reset\|aliases\|sh\|bash\|ksh\|csh\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(\\!sh\|!sh\|\\!bash\|!bash\|\\!ksh\|!ksh\|\\!csh\|!csh\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(blockf\|silent\|lucid\|trackbinds\|cloneonly\|nocd\|run-atpull\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(\|sh\|\!sh\|bash\|\!bash\|ksh\|\!ksh\|csh\|\!csh\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(nocompletions\|svn\|aliases\|trigger-load\)\>/ms=s+1
-syntax match ZinitIceModifiers /\s\<\%(light-mode\|is-snippet\|countdown\|ps-on-unload\|ps-on-update\)\>/ms=s+1
-
-" Include also ices added by the existing annexes
-syntax match ZinitIceModifiers /\s\<\%(test\|zman\|submod\|dl\|patch\|fbin\|sbin\|fsrc\|ferc\|fmod\|gem\|node\|rustup\|cargo\)\>/ms=s+1
-
-" Additional Zsh and Zinit functions
-syntax match ZshAndZinitFunctions /\<\%(compdef\|compinit\|zpcdreplay\|zpcdclear\|zpcompinit\|zpcompdef\)\>/
-
-" Link
-highlight def link ZshAndZinitFunctions Keyword
-highlight def link ZinitCommand Statement
-highlight def link ZinitSubCommands Title
-highlight def link ZinitPluginSubCommands Title
-highlight def link ZinitSnippetSubCommands Title
-highlight def link ZinitIceModifiers Type
-highlight def link ZinitSnippetShorthands1 Keyword
-highlight def link ZinitSnippetShorthands2 Keyword
-highlight def link ZinitPlugin1 Macro
-highlight def link ZinitPlugin2 Macro
-highlight def link ZinitPlugin3 Macro
-highlight def link ZinitSnippetUrl1 Macro
-highlight def link ZinitSnippetUrl2 Macro
-highlight def link ZinitSnippetUrl3 Macro
-highlight def link ZinitSnippetUrl4 Macro
-highlight def link ZinitTrailingWhiteSpace Error
+syn match ZinitCommand '\(^\|\s\)zinit\s'ms=e-5,me=e-1 skipwhite
+ \ nextgroup=ZinitCommand,ZinitIceCommand,ZinitPluginCommand,ZinitSnippetCommand,ZinitForCommand,ZinitContinue,ZinitIceWithParam,ZinitIce
+
+syn match ZinitCommand '\s\%(help\|man\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(unload\)\>'ms=s+1 skipwhite contained " load,light and snippet are handled elsewhere
+syn match ZinitCommand '\s\%(clist\|completions\|cdisable\|cenable\|creinstall\|cuninstall\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(csearch\|compinit\|cclear\|cdlist\|cdreplay\|cdclear\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(dtrace\|dstart\|dstop\|dunload\|dreport\|dclear\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(times\|zstatus\|report\|loaded\|list\|ls\|status\|recently\|bindkeys\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(compile\|uncompile\|compiled\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(self-update\|update\|delete\|cd\|edit\|glance\|stress\|changes\|create\)\>'ms=s+1 skipwhite contained
+syn match ZinitCommand '\s\%(srv\|recall\|env-whitelist\|module\|add-fpath\|fpath\|run\)\>'ms=s+1 skipwhite contained
+
+syn match ZinitIceCommand '\sice\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitIce,ZinitIceWithParam
+
+syn match ZinitPluginCommand '\s\%(light\|load\)\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitPlugin,ZinitContinue
+
+syn match ZinitSnippetCommand '\s\%(snippet\)\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitSnippet,ZinitContinue
+
+syn match ZinitForCommand '\sfor\s'ms=s+1,me=e-1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+
+syn cluster ZinitLine contains=ZinitIce,ZinitIceWithParam,ZinitPlugin,ZinitSnippet,ZinitForCommand
+
+syn match ZinitContinue '\s\\\s*$'ms=s+1,me=s+2 skipwhite contained skipnl
+ \ nextgroup=@ZinitLine
+
+" user/plugin or @user/plugin
+syn match ZinitPlugin '\s@\?\<[a-zA-Z0-9][a-zA-Z0-9_\-]*\/[a-zA-Z0-9_\-\.]\+\>'ms=s+1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+
+" shorthands
+syn match ZinitSnippet '\s\%(OMZ[LPT]\?\|PZT[M]\?\)::[a-zA-Z0-9_\-\.\/]\+\>'ms=s+1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+" url
+syn match ZinitSnippet '\s\%(http[s]\?\|ftp\):\/\/[[:alnum:]%\/_#.-]*\>'ms=s+1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+" "$VAR" local path
+syn match ZinitSnippet +\s"\$\<[a-zA-Z0-9_]\+[^"]*"+ms=s+1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+" "${VAR}" local path
+syn match ZinitSnippet +\s"\${\<[a-zA-Z0-9_]\+}[^"]*"+ms=s+1 skipwhite contained
+ \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
+
+" ices which takes a param enclosed in "
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(proto\|from\|ver\|bpick\|depth\|cloneopts\|pullopts\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(pick\|src\|multisrc\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wait\|load\|unload\|if\|has\|subscribe\|on-update-of\|trigger-load\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(mv\|cp\|atclone\|atpull\|atinit\|atload\|atdelete\|make\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(as\|id-as\|compile\|nocompile\|service\|bindmap\|wrap-track\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(extract\|subst\|autoload\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wrap\|ps-on-unload\|ps-on-update\)"+ skip=+\\"+ end=+"+ skipwhite contained
+
+" zinit packages
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(param\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+
+" added by the existing annexes
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(fbin\|sbin\|gem\|node\|pip\|fmod\|fsrc\|ferc\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(dl\|patch\|submods\|cargo\|dlink\|dlink0\)"+ skip=+\\"+ end=+"+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceDoubleQuoteParam
+
+syn match ZinitIceDoubleQuoteParam +[^"]*+ contained
+
+" ices that takes a param enclosed in '
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(proto\|from\|ver\|bpick\|depth\|cloneopts\|pullopts\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(pick\|src\|multisrc\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wait\|load\|unload\|if\|has\|subscribe\|on-update-of\|trigger-load\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(mv\|cp\|atclone\|atpull\|atinit\|atload\|atdelete\|make\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(as\|id-as\|compile\|nocompile\|service\|bindmap\|wrap-track\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(extract\|subst\|autoload\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wrap\|ps-on-unload\|ps-on-update\)'+ skip=+\\'+ end=+'+ skipwhite contained
+
+" zinit packages
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(param\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+
+" added by the existing annexes
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(fbin\|sbin\|gem\|node\|pip\|fmod\|fsrc\|ferc\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(dl\|patch\|submods\|cargo\|dlink\|dlink0\)'+ skip=+\\'+ end=+'+ skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+ \ contains=ZinitIceSingleQuoteParam
+
+syn match ZinitIceSingleQuoteParam +[^']*+ contained
+
+" ices that doens't take a param
+syn match ZinitIce '\s\%(teleid\|svn\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(wait\|cloneonly\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(silent\|lucid\|notify\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(blockf\|nocompletions\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(run-atpull\|nocd\|make\|countdown\|reset\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s!\?\%(sh\|bash\|ksh\|csh\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(id-as\|nocompile\|reset-prompt\|trackbinds\|aliases\|light-mode\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+syn match ZinitIce '\s\%(is-snippet\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+
+" ices that doens't take a param, from zinit packages
+syn match ZinitIce '\s\%(pack\|git\|null\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+
+" ices that doens't take a param, added by the existing annexes
+syn match ZinitIce '\s\%(notest\|rustup\|default-ice\|skip\|debug\)\>'ms=s+1 skipwhite contained
+ \ nextgroup=@ZinitLine,ZinitContinue
+
+" additional Zsh and zinit functions
+syn match ZshAndZinitFunctions '\<\%(compdef\|compinit\|zpcdreplay\|zpcdclear\|zpcompinit\|zpcompdef\)\>'
+
+" highlights
+hi def link ZinitCommand Statement
+hi def link ZinitCommand Title
+hi def link ZinitIceCommand Title
+hi def link ZinitPluginCommand Title
+hi def link ZinitSnippetCommand Title
+hi def link ZinitForCommand zshRepeat
+hi def link ZinitContinue Normal
+hi def link ZinitPlugin Macro
+hi def link ZinitSnippet Macro
+hi def link ZinitIce Type
+hi def link ZinitIceDoubleQuoteParam Special
+hi def link ZinitIceSingleQuoteParam Special
+hi def link ZshAndZinitFunctions Keyword
+
diff --git a/autoload/clojurecomplete.vim b/autoload/clojurecomplete.vim
index bc352ccb..35833004 100644
--- a/autoload/clojurecomplete.vim
+++ b/autoload/clojurecomplete.vim
@@ -13,7 +13,7 @@ endif
" -*- COMPLETION WORDS -*-
" Generated from https://github.com/clojure-vim/clojure.vim/blob/%%RELEASE_TAG%%/clj/src/vim_clojure_static/generate.clj
" Clojure version 1.10.3
-let s:words = ["*","*'","*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","+","+'","-","-'","->","->>","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods",".","..","/","<","<=","=","==",">",">=","EMPTY-NODE","Inst","PrintWriter-on","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-tap","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","amap","ancestors","and","any?","apply","areduce","array-map","as->","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assert","assoc!","assoc","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","binding","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","case","cast","cat","catch","char","char-array","char-escape-string","char-name-string","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","coll?","comment","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","cond","cond->","cond->>","condp","conj!","conj","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","declare","dedupe","def","default-data-readers","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","delay","delay?","deliver","denominator","deref","derive","descendants","destructure","disj!","disj","dissoc!","dissoc","distinct","distinct?","do","doall","dorun","doseq","dosync","dotimes","doto","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-cause","ex-data","ex-info","ex-message","extend","extend-protocol","extend-type","extenders","extends?","false?","ffirst","file-seq","filter","filterv","finally","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn","fn","fn?","fnext","fnil","for","force","format","frequencies","future","future-call","future-cancel","future-cancelled?","future-done?","future?","gen-class","gen-interface","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","if","if-let","if-not","if-some","ifn?","import","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","io!","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","lazy-cat","lazy-seq","let","let","letfn","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","locking","long","long-array","longs","loop","loop","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memfn","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","monitor-enter","monitor-exit","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","new","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","or","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop!","pop","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","primitives-classnames","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy","proxy-call-with-super","proxy-mappings","proxy-name","proxy-super","push-thread-bindings","pvalues","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","quote","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read+string","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","recur","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","refer-clojure","reify","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-tap","remove-watch","repeat","repeatedly","replace","replicate","require","requiring-resolve","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set!","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some->","some->>","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","sync","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","tap>","test","the-ns","thread-bound?","throw","time","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","try","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unquote","unquote-splicing","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","vswap!","when","when-first","when-let","when-not","when-some","while","with-bindings","with-bindings*","with-in-str","with-loading-context","with-local-vars","with-meta","with-open","with-out-str","with-precision","with-redefs","with-redefs-fn","xml-seq","zero?","zipmap"]
+let s:words = ["&","*","*'","*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","+","+'","-","-'","->","->>","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods",".","..","/","<","<=","=","==",">",">=","EMPTY-NODE","Inst","PrintWriter-on","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-tap","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","amap","ancestors","and","any?","apply","areduce","array-map","as->","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assert","assoc","assoc!","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","binding","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","case","case*","cast","cat","catch","char","char-array","char-escape-string","char-name-string","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","coll?","comment","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","cond","cond->","cond->>","condp","conj","conj!","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","declare","dedupe","def","default-data-readers","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","deftype*","delay","delay?","deliver","denominator","deref","derive","descendants","destructure","disj","disj!","dissoc","dissoc!","distinct","distinct?","do","doall","dorun","doseq","dosync","dotimes","doto","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-cause","ex-data","ex-info","ex-message","extend","extend-protocol","extend-type","extenders","extends?","false","false?","ffirst","file-seq","filter","filterv","finally","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn","fn*","fn?","fnext","fnil","for","force","format","frequencies","future","future-call","future-cancel","future-cancelled?","future-done?","future?","gen-class","gen-interface","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","if","if-let","if-not","if-some","ifn?","import","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","io!","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","lazy-cat","lazy-seq","let","let*","letfn","letfn*","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","locking","long","long-array","longs","loop","loop*","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memfn","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","monitor-enter","monitor-exit","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","new","newline","next","nfirst","nil","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","or","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop","pop!","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","primitives-classnames","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy","proxy-call-with-super","proxy-mappings","proxy-name","proxy-super","push-thread-bindings","pvalues","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","quote","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read+string","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","recur","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","refer-clojure","reify","reify*","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-tap","remove-watch","repeat","repeatedly","replace","replicate","require","requiring-resolve","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set","set!","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some->","some->>","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","sync","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","tap>","test","the-ns","thread-bound?","throw","time","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true","true?","try","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unquote","unquote-splicing","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","vswap!","when","when-first","when-let","when-not","when-some","while","with-bindings","with-bindings*","with-in-str","with-loading-context","with-local-vars","with-meta","with-open","with-out-str","with-precision","with-redefs","with-redefs-fn","xml-seq","zero?","zipmap"]
" Simple word completion for special forms and public vars in clojure.core
function! clojurecomplete#Complete(findstart, base)
diff --git a/autoload/csv.vim b/autoload/csv.vim
index 34943bc7..ba04d2bc 100644
--- a/autoload/csv.vim
+++ b/autoload/csv.vim
@@ -780,8 +780,7 @@ fu! csv#CalculateColumnWidth(row, silent) "{{{3
" row for the row for which to calculate the width
let b:col_width=[]
if has( 'vartabs' ) && b:delimiter == "\t"
- let vts_save=&vts
- set vts=
+ setlocal vts=
endif
try
if exists("b:csv_headerline")
@@ -801,9 +800,6 @@ fu! csv#CalculateColumnWidth(row, silent) "{{{3
" delete buffer content in variable b:csv_list,
" this was only necessary for calculating the max width
unlet! b:csv_list s:columnize_count s:decimal_column
- if has( 'vartabs' ) && b:delimiter == "\t"
- let &vts=vts_save
- endif
endfu
fu! csv#Columnize(field) "{{{3
" Internal function, not called from external,
diff --git a/autoload/dart.vim b/autoload/dart.vim
index a5733d03..28e55552 100644
--- a/autoload/dart.vim
+++ b/autoload/dart.vim
@@ -90,18 +90,6 @@ function! s:FindDartFmt() abort
return []
endfunction
-function! dart#analyzer(q_args) abort
- call s:error('DartAnalyzer support has been removed. '.
- \'If this broke your workflow please comment on '.
- \'https://github.com/dart-lang/dart-vim-plugin/issues/89')
-endfunction
-
-function! dart#tojs(q_args) abort
- call s:error('Dart2JS support has been removed. '.
- \'If this broke your workflow please comment on '.
- \'https://github.com/dart-lang/dart-vim-plugin/issues/89')
-endfunction
-
" Finds the path to `uri`.
"
" If the file is a package: uri, looks for a .packages file to resolve the path.
diff --git a/autoload/freebasic.vim b/autoload/freebasic.vim
new file mode 100644
index 00000000..50be9045
--- /dev/null
+++ b/autoload/freebasic.vim
@@ -0,0 +1,45 @@
+if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'autoload/freebasic.vim')
+ finish
+endif
+
+" Vim filetype plugin file
+" Language: FreeBASIC
+" Maintainer: Doug Kearns <dougkearns@gmail.com>
+" Last Change: 2021 Mar 16
+
+" Dialects can be one of fb, qb, fblite, or deprecated
+" Precedence is forcelang > #lang > lang
+function! freebasic#GetDialect() abort
+ if exists("g:freebasic_forcelang")
+ return g:freebasic_forcelang
+ endif
+
+ if exists("g:freebasic_lang")
+ let dialect = g:freebasic_lang
+ else
+ let dialect = "fb"
+ endif
+
+ " override with #lang directive or metacommand
+
+ let skip = "has('syntax_items') && synIDattr(synID(line('.'), col('.'), 1), 'name') =~ 'Comment$'"
+ let pat = '\c^\s*\%(#\s*lang\s\+\|''\s*$lang\s*:\s*\)"\([^"]*\)"'
+
+ let save_cursor = getcurpos()
+ call cursor(1, 1)
+ let lnum = search(pat, 'n', '', '', skip)
+ call setpos('.', save_cursor)
+
+ if lnum
+ let word = matchlist(getline(lnum), pat)[1]
+ if word =~? '\%(fb\|deprecated\|fblite\|qb\)'
+ let dialect = word
+ else
+ echomsg "freebasic#GetDialect: Invalid lang, found '" .. word .. "' at line " .. lnum .. " " .. getline(lnum)
+ endif
+ endif
+
+ return dialect
+endfunction
+
+" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:
diff --git a/autoload/fsharp.vim b/autoload/fsharp.vim
index 5d8bb79d..275913cf 100644
--- a/autoload/fsharp.vim
+++ b/autoload/fsharp.vim
@@ -238,11 +238,7 @@ function! fsharp#loadConfig()
endif
if !exists('g:fsharp#fsautocomplete_command')
- let s:fsac = fnamemodify(s:script_root_dir . "fsac/fsautocomplete.dll", ":p")
- let g:fsharp#fsautocomplete_command =
- \ ['dotnet', s:fsac,
- \ '--background-service-enabled'
- \ ]
+ let g:fsharp#fsautocomplete_command = ['fsautocomplete', '--background-service-enabled']
endif
if !exists('g:fsharp#use_recommended_server_config')
let g:fsharp#use_recommended_server_config = 1
@@ -283,6 +279,7 @@ function! fsharp#loadConfig()
" backend configuration
if g:fsharp#backend == 'languageclient-neovim'
+ let $DOTNET_ROLL_FORWARD='LatestMajor'
if !exists('g:LanguageClient_serverCommands')
let g:LanguageClient_serverCommands = {}
endif
@@ -478,8 +475,17 @@ function! fsharp#OnCursorMove()
endfunction
function! fsharp#showF1Help()
- let result = s:f1Help(expand('%:p'), line('.') - 1, col('.') - 1)
- echo result
+ function! s:callback_showF1Help(result)
+ let result = a:result
+ if exists('result.result.content')
+ let content = json_decode(result.result.content)
+ if exists('content.Data')
+ let url = 'https://docs.microsoft.com/en-us/dotnet/api/' . substitute(content.Data, '#ctor', '-ctor', 'g')
+ echo url
+ endif
+ endif
+ endfunction
+ call s:f1Help(expand('%:p'), line('.') - 1, col('.') - 1, function("s:callback_showF1Help"))
endfunction
function! s:hover()
@@ -505,39 +511,6 @@ function! fsharp#showTooltip()
endfunction
-" FSAC update utils
-
-function! s:update_win()
- echom "[FSAC] Downloading FSAC. This may take a while..."
- let script = s:script_root_dir . "install.ps1"
- call system('powershell -ExecutionPolicy Unrestricted ' . script . " update")
-endfunction
-
-function! s:update_unix()
- echom "[FSAC] Downloading FSAC. This may take a while..."
- let zip = s:script_root_dir . "fsac.zip"
- call system(
- \ 'curl -fLo ' . zip . ' --create-dirs ' .
- \ '"https://github.com/fsharp/FsAutoComplete/releases/latest/download/fsautocomplete.netcore.zip"'
- \ )
- if v:shell_error == 0
- call system('unzip -o -d ' . s:script_root_dir . "/fsac " . zip)
- call system('find ' . s:script_root_dir . '/fsac' . ' -type f -exec chmod 777 \{\} \;')
- echom "[FSAC] Updated FsAutoComplete"
- else
- echom "[FSAC] Failed to update FsAutoComplete"
- endif
-endfunction
-
-function! fsharp#updateFSAC(...)
- if has('win32') && !has('win32unix')
- call s:update_win()
- else
- call s:update_unix()
- endif
-endfunction
-
-
" FSI integration
let s:fsi_buffer = -1
diff --git a/autoload/polyglot/ft.vim b/autoload/polyglot/ft.vim
index 2ba69ed1..a8ca9008 100644
--- a/autoload/polyglot/ft.vim
+++ b/autoload/polyglot/ft.vim
@@ -1,113 +1,127 @@
-" Vim functions for file type detection
-"
-" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2021 Dec 17
+vim9script
-" These functions are moved here from runtime/filetype.vim to make startup
-" faster.
+# Vim functions for file type detection
+#
+# Maintainer: Bram Moolenaar <Bram@vim.org>
+# Last Change: 2022 Feb 05
-" Line continuation is used here, remove 'C' from 'cpoptions'
-let s:cpo_save = &cpo
-set cpo&vim
+# These functions are moved here from runtime/filetype.vim to make startup
+# faster.
-func polyglot#ft#Check_inp()
+export def Check_inp()
if getline(1) =~ '^\*'
setf abaqus
else
- let n = 1
- if line("$") > 500
- let nmax = 500
- else
- let nmax = line("$")
- endif
+ var n = 1
+ var nmax = line("$") > 500 ? 500 : line("$")
while n <= nmax
if getline(n) =~? "^header surface data"
setf trasys
break
endif
- let n = n + 1
+ n += 1
endwhile
endif
-endfunc
+enddef
-" This function checks for the kind of assembly that is wanted by the user, or
-" can be detected from the first five lines of the file.
-func polyglot#ft#FTasm()
- " make sure b:asmsyntax exists
+# This function checks for the kind of assembly that is wanted by the user, or
+# can be detected from the first five lines of the file.
+export def FTasm()
+ # make sure b:asmsyntax exists
if !exists("b:asmsyntax")
- let b:asmsyntax = ""
+ b:asmsyntax = ""
endif
if b:asmsyntax == ""
- call polyglot#ft#FTasmsyntax()
+ FTasmsyntax()
endif
- " if b:asmsyntax still isn't set, default to asmsyntax or GNU
+ # if b:asmsyntax still isn't set, default to asmsyntax or GNU
if b:asmsyntax == ""
if exists("g:asmsyntax")
- let b:asmsyntax = g:asmsyntax
+ b:asmsyntax = g:asmsyntax
else
- let b:asmsyntax = "asm"
+ b:asmsyntax = "asm"
endif
endif
- exe "setf " . fnameescape(b:asmsyntax)
-endfunc
+ exe "setf " .. fnameescape(b:asmsyntax)
+enddef
-func polyglot#ft#FTasmsyntax()
- " see if file contains any asmsyntax=foo overrides. If so, change
- " b:asmsyntax appropriately
- let head = " ".getline(1)." ".getline(2)." ".getline(3)." ".getline(4).
- \" ".getline(5)." "
- let match = matchstr(head, '\sasmsyntax=\zs[a-zA-Z0-9]\+\ze\s')
+export def FTasmsyntax()
+ # see if the file contains any asmsyntax=foo overrides. If so, change
+ # b:asmsyntax appropriately
+ var head = " " .. getline(1) .. " " .. getline(2) .. " "
+ .. getline(3) .. " " .. getline(4) .. " " .. getline(5) .. " "
+ var match = matchstr(head, '\sasmsyntax=\zs[a-zA-Z0-9]\+\ze\s')
if match != ''
- let b:asmsyntax = match
+ b:asmsyntax = match
elseif ((head =~? '\.title') || (head =~? '\.ident') || (head =~? '\.macro') || (head =~? '\.subtitle') || (head =~? '\.library'))
- let b:asmsyntax = "vmasm"
+ b:asmsyntax = "vmasm"
+ endif
+enddef
+
+var ft_visual_basic_content = '\cVB_Name\|Begin VB\.\(Form\|MDIForm\|UserControl\)'
+
+# See FTfrm() for Visual Basic form file detection
+export def FTbas()
+ if exists("g:filetype_bas")
+ exe "setf " .. g:filetype_bas
+ return
endif
-endfunc
-" Check if one of the first five lines contains "VB_Name". In that case it is
-" probably a Visual Basic file. Otherwise it's assumed to be "alt" filetype.
-func polyglot#ft#FTVB(alt)
- if getline(1).getline(2).getline(3).getline(4).getline(5) =~? 'VB_Name\|Begin VB\.\(Form\|MDIForm\|UserControl\)'
+ # most frequent FreeBASIC-specific keywords in distro files
+ var fb_keywords = '\c^\s*\%(extern\|var\|enum\|private\|scope\|union\|byref\|operator\|constructor\|delete\|namespace\|public\|property\|with\|destructor\|using\)\>\%(\s*[:=(]\)\@!'
+ var fb_preproc = '\c^\s*\%(#\a\+\|option\s\+\%(byval\|dynamic\|escape\|\%(no\)\=gosub\|nokeyword\|private\|static\)\>\)'
+ var fb_comment = "^\\s*/'"
+ # OPTION EXPLICIT, without the leading underscore, is common to many dialects
+ var qb64_preproc = '\c^\s*\%($\a\+\|option\s\+\%(_explicit\|_\=explicitarray\)\>\)'
+
+ var lines = getline(1, min([line("$"), 100]))
+
+ if match(lines, fb_preproc) > -1 || match(lines, fb_comment) > -1 || match(lines, fb_keywords) > -1
+ setf freebasic
+ elseif match(lines, qb64_preproc) > -1
+ setf qb64
+ elseif match(lines, s:ft_visual_basic_content) > -1
setf vb
else
- exe "setf " . a:alt
+ setf basic
endif
-endfunc
+enddef
-func polyglot#ft#FTbtm()
+export def FTbtm()
if exists("g:dosbatch_syntax_for_btm") && g:dosbatch_syntax_for_btm
setf dosbatch
else
setf btm
endif
-endfunc
+enddef
-func polyglot#ft#BindzoneCheck(default)
- if getline(1).getline(2).getline(3).getline(4) =~ '^; <<>> DiG [0-9.]\+.* <<>>\|$ORIGIN\|$TTL\|IN\s\+SOA'
+export def BindzoneCheck(default = '')
+ if getline(1) .. getline(2) .. getline(3) .. getline(4)
+ =~ '^; <<>> DiG [0-9.]\+.* <<>>\|$ORIGIN\|$TTL\|IN\s\+SOA'
setf bindzone
- elseif a:default != ''
- exe 'setf ' . a:default
+ elseif default != ''
+ exe 'setf ' .. default
endif
-endfunc
+enddef
-func polyglot#ft#FTlpc()
+export def FTlpc()
if exists("g:lpc_syntax_for_c")
- let lnum = 1
+ var lnum = 1
while lnum <= 12
if getline(lnum) =~# '^\(//\|inherit\|private\|protected\|nosave\|string\|object\|mapping\|mixed\)'
setf lpc
return
endif
- let lnum = lnum + 1
+ lnum += 1
endwhile
endif
setf c
-endfunc
+enddef
-func polyglot#ft#FTheader()
+export def FTheader()
if match(getline(1, min([line("$"), 200])), '^@\(interface\|end\|class\)') > -1
if exists("g:c_syntax_for_h")
setf objc
@@ -121,15 +135,15 @@ func polyglot#ft#FTheader()
else
setf cpp
endif
-endfunc
+enddef
-" This function checks if one of the first ten lines start with a '@'. In
-" that case it is probably a change file.
-" If the first line starts with # or ! it's probably a ch file.
-" If a line has "main", "include", "//" or "/*" it's probably ch.
-" Otherwise CHILL is assumed.
-func polyglot#ft#FTchange()
- let lnum = 1
+# This function checks if one of the first ten lines start with a '@'. In
+# that case it is probably a change file.
+# If the first line starts with # or ! it's probably a ch file.
+# If a line has "main", "include", "//" or "/*" it's probably ch.
+# Otherwise CHILL is assumed.
+export def FTchange()
+ var lnum = 1
while lnum <= 10
if getline(lnum)[0] == '@'
setf change
@@ -147,86 +161,101 @@ func polyglot#ft#FTchange()
setf ch
return
endif
- let lnum = lnum + 1
+ lnum += 1
endwhile
setf chill
-endfunc
+enddef
-func polyglot#ft#FTent()
- " This function checks for valid cl syntax in the first five lines.
- " Look for either an opening comment, '#', or a block start, '{".
- " If not found, assume SGML.
- let lnum = 1
+export def FTent()
+ # This function checks for valid cl syntax in the first five lines.
+ # Look for either an opening comment, '#', or a block start, '{".
+ # If not found, assume SGML.
+ var lnum = 1
while lnum < 6
- let line = getline(lnum)
+ var line = getline(lnum)
if line =~ '^\s*[#{]'
setf cl
return
elseif line !~ '^\s*$'
- " Not a blank line, not a comment, and not a block start,
- " so doesn't look like valid cl code.
+ # Not a blank line, not a comment, and not a block start,
+ # so doesn't look like valid cl code.
break
endif
- let lnum = lnum + 1
+ lnum += 1
endw
setf dtd
-endfunc
+enddef
-func polyglot#ft#ExCheck()
- let lines = getline(1, min([line("$"), 100]))
+export def ExCheck()
+ var lines = getline(1, min([line("$"), 100]))
if exists('g:filetype_euphoria')
- exe 'setf ' . g:filetype_euphoria
+ exe 'setf ' .. g:filetype_euphoria
elseif match(lines, '^--\|^ifdef\>\|^include\>') > -1
setf euphoria3
else
setf elixir
endif
-endfunc
+enddef
-func polyglot#ft#EuphoriaCheck()
+export def EuphoriaCheck()
if exists('g:filetype_euphoria')
- exe 'setf ' . g:filetype_euphoria
+ exe 'setf ' .. g:filetype_euphoria
else
setf euphoria3
endif
-endfunc
+enddef
-func polyglot#ft#DtraceCheck()
- let lines = getline(1, min([line("$"), 100]))
+export def DtraceCheck()
+ var lines = getline(1, min([line("$"), 100]))
if match(lines, '^module\>\|^import\>') > -1
- " D files often start with a module and/or import statement.
+ # D files often start with a module and/or import statement.
setf d
elseif match(lines, '^#!\S\+dtrace\|#pragma\s\+D\s\+option\|:\S\{-}:\S\{-}:') > -1
setf dtrace
else
setf d
endif
-endfunc
+enddef
-func polyglot#ft#FTe()
+export def FTe()
if exists('g:filetype_euphoria')
- exe 'setf ' . g:filetype_euphoria
+ exe 'setf ' .. g:filetype_euphoria
else
- let n = 1
+ var n = 1
while n < 100 && n <= line("$")
if getline(n) =~ "^\\s*\\(<'\\|'>\\)\\s*$"
setf specman
return
endif
- let n = n + 1
+ n += 1
endwhile
setf eiffel
endif
-endfunc
+enddef
+
+export def FTfrm()
+ if exists("g:filetype_frm")
+ exe "setf " .. g:filetype_frm
+ return
+ endif
+
+ var lines = getline(1, min([line("$"), 5]))
-" Distinguish between Forth and F#.
-" Provided by Doug Kearns.
-func polyglot#ft#FTfs()
+ if match(lines, s:ft_visual_basic_content) > -1
+ setf vb
+ else
+ setf form
+ endif
+enddef
+
+# Distinguish between Forth and F#.
+# Provided by Doug Kearns.
+export def FTfs()
if exists("g:filetype_fs")
- exe "setf " . g:filetype_fs
+ exe "setf " .. g:filetype_fs
else
- let line = getline(nextnonblank(1))
- " comments and colon definitions
+ var line = getline(nextnonblank(1))
+ # comments and colon definitions
if line =~ '^\s*\.\=( ' || line =~ '^\s*\\G\= ' || line =~ '^\\$'
\ || line =~ '^\s*: \S'
setf forth
@@ -234,11 +263,11 @@ func polyglot#ft#FTfs()
setf fsharp
endif
endif
-endfunc
+enddef
-" Distinguish between HTML, XHTML and Django
-func polyglot#ft#FThtml()
- let n = 1
+# Distinguish between HTML, XHTML and Django
+export def FThtml()
+ var n = 1
while n < 10 && n <= line("$")
if getline(n) =~ '\<DTD\s\+XHTML\s'
setf xhtml
@@ -248,58 +277,58 @@ func polyglot#ft#FThtml()
setf htmldjango
return
endif
- let n = n + 1
+ n += 1
endwhile
setf FALLBACK html
-endfunc
+enddef
-" Distinguish between standard IDL and MS-IDL
-func polyglot#ft#FTidl()
- let n = 1
+# Distinguish between standard IDL and MS-IDL
+export def FTidl()
+ var n = 1
while n < 50 && n <= line("$")
if getline(n) =~ '^\s*import\s\+"\(unknwn\|objidl\)\.idl"'
setf msidl
return
endif
- let n = n + 1
+ n += 1
endwhile
setf idl
-endfunc
-
-" Distinguish between "default" and Cproto prototype file. */
-func polyglot#ft#ProtoCheck(default)
- " Cproto files have a comment in the first line and a function prototype in
- " the second line, it always ends in ";". Indent files may also have
- " comments, thus we can't match comments to see the difference.
- " IDL files can have a single ';' in the second line, require at least one
- " chacter before the ';'.
+enddef
+
+# Distinguish between "default" and Cproto prototype file. */
+export def ProtoCheck(default: string)
+ # Cproto files have a comment in the first line and a function prototype in
+ # the second line, it always ends in ";". Indent files may also have
+ # comments, thus we can't match comments to see the difference.
+ # IDL files can have a single ';' in the second line, require at least one
+ # chacter before the ';'.
if getline(2) =~ '.;$'
setf cpp
else
- exe 'setf ' . a:default
+ exe 'setf ' .. default
endif
-endfunc
+enddef
-func polyglot#ft#FTm()
+export def FTm()
if exists("g:filetype_m")
- exe "setf " . g:filetype_m
+ exe "setf " .. g:filetype_m
return
endif
- " excluding end(for|function|if|switch|while) common to Murphi
- let octave_block_terminators = '\<end\%(_try_catch\|classdef\|enumeration\|events\|methods\|parfor\|properties\)\>'
+ # excluding end(for|function|if|switch|while) common to Murphi
+ var octave_block_terminators = '\<end\%(_try_catch\|classdef\|enumeration\|events\|methods\|parfor\|properties\)\>'
- let objc_preprocessor = '^\s*#\s*\%(import\|include\|define\|if\|ifn\=def\|undef\|line\|error\|pragma\)\>'
+ var objc_preprocessor = '^\s*#\s*\%(import\|include\|define\|if\|ifn\=def\|undef\|line\|error\|pragma\)\>'
- let n = 1
- let saw_comment = 0 " Whether we've seen a multiline comment leader.
+ var n = 1
+ var saw_comment = 0 # Whether we've seen a multiline comment leader.
while n < 100
- let line = getline(n)
+ var line = getline(n)
if line =~ '^\s*/\*'
- " /* ... */ is a comment in Objective C and Murphi, so we can't conclude
- " it's either of them yet, but track this as a hint in case we don't see
- " anything more definitive.
- let saw_comment = 1
+ # /* ... */ is a comment in Objective C and Murphi, so we can't conclude
+ # it's either of them yet, but track this as a hint in case we don't see
+ # anything more definitive.
+ saw_comment = 1
endif
if line =~ '^\s*//' || line =~ '^\s*@import\>' || line =~ objc_preprocessor
setf objc
@@ -310,7 +339,7 @@ func polyglot#ft#FTm()
setf octave
return
endif
- " TODO: could be Matlab or Octave
+ # TODO: could be Matlab or Octave
if line =~ '^\s*%'
setf matlab
return
@@ -323,24 +352,24 @@ func polyglot#ft#FTm()
setf murphi
return
endif
- let n = n + 1
+ n += 1
endwhile
if saw_comment
- " We didn't see anything definitive, but this looks like either Objective C
- " or Murphi based on the comment leader. Assume the former as it is more
- " common.
+ # We didn't see anything definitive, but this looks like either Objective C
+ # or Murphi based on the comment leader. Assume the former as it is more
+ # common.
setf objc
else
- " Default is Matlab
+ # Default is Matlab
setf matlab
endif
-endfunc
+enddef
-func polyglot#ft#FTmms()
- let n = 1
+export def FTmms()
+ var n = 1
while n < 20
- let line = getline(n)
+ var line = getline(n)
if line =~ '^\s*\(%\|//\)' || line =~ '^\*'
setf mmix
return
@@ -349,78 +378,78 @@ func polyglot#ft#FTmms()
setf make
return
endif
- let n = n + 1
+ n += 1
endwhile
setf mmix
-endfunc
+enddef
-" This function checks if one of the first five lines start with a dot. In
-" that case it is probably an nroff file: 'filetype' is set and 1 is returned.
-func polyglot#ft#FTnroff()
- if getline(1)[0] . getline(2)[0] . getline(3)[0] . getline(4)[0] . getline(5)[0] =~ '\.'
+# This function checks if one of the first five lines start with a dot. In
+# that case it is probably an nroff file: 'filetype' is set and 1 is returned.
+export def FTnroff(): number
+ if getline(1)[0] .. getline(2)[0] .. getline(3)[0]
+ .. getline(4)[0] .. getline(5)[0] =~ '\.'
setf nroff
return 1
endif
return 0
-endfunc
+enddef
-func polyglot#ft#FTmm()
- let n = 1
+export def FTmm()
+ var n = 1
while n < 20
- let line = getline(n)
- if line =~ '^\s*\(#\s*\(include\|import\)\>\|@import\>\|/\*\)'
+ if getline(n) =~ '^\s*\(#\s*\(include\|import\)\>\|@import\>\|/\*\)'
setf objcpp
return
endif
- let n = n + 1
+ n += 1
endwhile
setf nroff
-endfunc
+enddef
-func polyglot#ft#FTpl()
+export def FTpl()
if exists("g:filetype_pl")
- exe "setf " . g:filetype_pl
+ exe "setf " .. g:filetype_pl
else
- " recognize Prolog by specific text in the first non-empty line
- " require a blank after the '%' because Perl uses "%list" and "%translate"
- let l = getline(nextnonblank(1))
+ # recognize Prolog by specific text in the first non-empty line
+ # require a blank after the '%' because Perl uses "%list" and "%translate"
+ var l = getline(nextnonblank(1))
if l =~ '\<prolog\>' || l =~ '^\s*\(%\+\(\s\|$\)\|/\*\)' || l =~ ':-'
setf prolog
else
setf perl
endif
endif
-endfunc
+enddef
-func polyglot#ft#FTinc()
+export def FTinc()
if exists("g:filetype_inc")
- exe "setf " . g:filetype_inc
+ exe "setf " .. g:filetype_inc
else
- let lines = getline(1).getline(2).getline(3)
+ var lines = getline(1) .. getline(2) .. getline(3)
if lines =~? "perlscript"
setf aspperl
elseif lines =~ "<%"
setf aspvbs
elseif lines =~ "<?"
setf php
- " Pascal supports // comments but they're vary rarely used for file
- " headers so assume POV-Ray
+ # Pascal supports // comments but they're vary rarely used for file
+ # headers so assume POV-Ray
elseif lines =~ '^\s*\%({\|(\*\)' || lines =~? s:ft_pascal_keywords
setf pascal
else
- call polyglot#ft#FTasmsyntax()
+ FTasmsyntax()
if exists("b:asmsyntax")
- exe "setf " . fnameescape(b:asmsyntax)
+ exe "setf " .. fnameescape(b:asmsyntax)
else
setf pov
endif
endif
endif
-endfunc
+enddef
-func polyglot#ft#FTprogress_cweb()
+export def FTprogress_cweb()
if exists("g:filetype_w")
- exe "setf " . g:filetype_w
+ exe "setf " .. g:filetype_w
return
endif
if getline(1) =~ '&ANALYZE' || getline(3) =~ '&GLOBAL-DEFINE'
@@ -428,76 +457,76 @@ func polyglot#ft#FTprogress_cweb()
else
setf cweb
endif
-endfunc
+enddef
-func polyglot#ft#FTprogress_asm()
+export def FTprogress_asm()
if exists("g:filetype_i")
- exe "setf " . g:filetype_i
+ exe "setf " .. g:filetype_i
return
endif
- " This function checks for an assembly comment the first ten lines.
- " If not found, assume Progress.
- let lnum = 1
+ # This function checks for an assembly comment the first ten lines.
+ # If not found, assume Progress.
+ var lnum = 1
while lnum <= 10 && lnum < line('$')
- let line = getline(lnum)
+ var line = getline(lnum)
if line =~ '^\s*;' || line =~ '^\*'
- call polyglot#ft#FTasm()
+ FTasm()
return
elseif line !~ '^\s*$' || line =~ '^/\*'
- " Not an empty line: Doesn't look like valid assembly code.
- " Or it looks like a Progress /* comment
+ # Not an empty line: Doesn't look like valid assembly code.
+ # Or it looks like a Progress /* comment
break
endif
- let lnum = lnum + 1
+ lnum += 1
endw
setf progress
-endfunc
+enddef
-let s:ft_pascal_comments = '^\s*\%({\|(\*\|//\)'
-let s:ft_pascal_keywords = '^\s*\%(program\|unit\|library\|uses\|begin\|procedure\|function\|const\|type\|var\)\>'
+var ft_pascal_comments = '^\s*\%({\|(\*\|//\)'
+var ft_pascal_keywords = '^\s*\%(program\|unit\|library\|uses\|begin\|procedure\|function\|const\|type\|var\)\>'
-func polyglot#ft#FTprogress_pascal()
+export def FTprogress_pascal()
if exists("g:filetype_p")
- exe "setf " . g:filetype_p
+ exe "setf " .. g:filetype_p
return
endif
- " This function checks for valid Pascal syntax in the first ten lines.
- " Look for either an opening comment or a program start.
- " If not found, assume Progress.
- let lnum = 1
+ # This function checks for valid Pascal syntax in the first ten lines.
+ # Look for either an opening comment or a program start.
+ # If not found, assume Progress.
+ var lnum = 1
while lnum <= 10 && lnum < line('$')
- let line = getline(lnum)
+ var line = getline(lnum)
if line =~ s:ft_pascal_comments || line =~? s:ft_pascal_keywords
setf pascal
return
elseif line !~ '^\s*$' || line =~ '^/\*'
- " Not an empty line: Doesn't look like valid Pascal code.
- " Or it looks like a Progress /* comment
+ # Not an empty line: Doesn't look like valid Pascal code.
+ # Or it looks like a Progress /* comment
break
endif
- let lnum = lnum + 1
+ lnum += 1
endw
setf progress
-endfunc
+enddef
-func polyglot#ft#FTpp()
+export def FTpp()
if exists("g:filetype_pp")
- exe "setf " . g:filetype_pp
+ exe "setf " .. g:filetype_pp
else
- let line = getline(nextnonblank(1))
+ var line = getline(nextnonblank(1))
if line =~ s:ft_pascal_comments || line =~? s:ft_pascal_keywords
setf pascal
else
setf puppet
endif
endif
-endfunc
+enddef
-func polyglot#ft#FTr()
- let max = line("$") > 50 ? 50 : line("$")
+export def FTr()
+ var max = line("$") > 50 ? 50 : line("$")
for n in range(1, max)
- " Rebol is easy to recognize, check for that first
+ # Rebol is easy to recognize, check for that first
if getline(n) =~? '\<REBOL\>'
setf rebol
return
@@ -505,82 +534,82 @@ func polyglot#ft#FTr()
endfor
for n in range(1, max)
- " R has # comments
+ # R has # comments
if getline(n) =~ '^\s*#'
setf r
return
endif
- " Rexx has /* comments */
+ # Rexx has /* comments */
if getline(n) =~ '^\s*/\*'
setf rexx
return
endif
endfor
- " Nothing recognized, use user default or assume Rexx
+ # Nothing recognized, use user default or assume Rexx
if exists("g:filetype_r")
- exe "setf " . g:filetype_r
+ exe "setf " .. g:filetype_r
else
- " Rexx used to be the default, but R appears to be much more popular.
+ # Rexx used to be the default, but R appears to be much more popular.
setf r
endif
-endfunc
+enddef
-func polyglot#ft#McSetf()
- " Rely on the file to start with a comment.
- " MS message text files use ';', Sendmail files use '#' or 'dnl'
+export def McSetf()
+ # Rely on the file to start with a comment.
+ # MS message text files use ';', Sendmail files use '#' or 'dnl'
for lnum in range(1, min([line("$"), 20]))
- let line = getline(lnum)
+ var line = getline(lnum)
if line =~ '^\s*\(#\|dnl\)'
- setf m4 " Sendmail .mc file
+ setf m4 # Sendmail .mc file
return
elseif line =~ '^\s*;'
- setf msmessages " MS Message text file
+ setf msmessages # MS Message text file
return
endif
endfor
setf m4 " Default: Sendmail .mc file
-endfunc
+enddef
-" Called from filetype.vim and scripts.vim.
-func polyglot#ft#SetFileTypeSH(name)
+# Called from filetype.vim and scripts.vim.
+export def SetFileTypeSH(name: string)
if did_filetype()
- " Filetype was already detected
+ # Filetype was already detected
return
endif
if expand("<amatch>") =~ g:ft_ignore_pat
return
endif
- if a:name =~ '\<csh\>'
- " Some .sh scripts contain #!/bin/csh.
- call polyglot#ft#SetFileTypeShell("csh")
+ if name =~ '\<csh\>'
+ # Some .sh scripts contain #!/bin/csh.
+ SetFileTypeShell("csh")
return
- elseif a:name =~ '\<tcsh\>'
- " Some .sh scripts contain #!/bin/tcsh.
- call polyglot#ft#SetFileTypeShell("tcsh")
+ elseif name =~ '\<tcsh\>'
+ # Some .sh scripts contain #!/bin/tcsh.
+ SetFileTypeShell("tcsh")
return
- elseif a:name =~ '\<zsh\>'
- " Some .sh scripts contain #!/bin/zsh.
- call polyglot#ft#SetFileTypeShell("zsh")
+ elseif name =~ '\<zsh\>'
+ # Some .sh scripts contain #!/bin/zsh.
+ SetFileTypeShell("zsh")
return
- elseif a:name =~ '\<ksh\>'
- let b:is_kornshell = 1
+ elseif name =~ '\<ksh\>'
+ b:is_kornshell = 1
if exists("b:is_bash")
unlet b:is_bash
endif
if exists("b:is_sh")
unlet b:is_sh
endif
- elseif exists("g:bash_is_sh") || a:name =~ '\<bash\>' || a:name =~ '\<bash2\>'
- let b:is_bash = 1
+ elseif exists("g:bash_is_sh") || name =~ '\<bash\>' || name =~ '\<bash2\>'
+ b:is_bash = 1
if exists("b:is_kornshell")
unlet b:is_kornshell
endif
if exists("b:is_sh")
unlet b:is_sh
endif
- elseif a:name =~ '\<sh\>'
- let b:is_sh = 1
+ elseif name =~ '\<sh\>'
+ b:is_sh = 1
if exists("b:is_kornshell")
unlet b:is_kornshell
endif
@@ -588,75 +617,76 @@ func polyglot#ft#SetFileTypeSH(name)
unlet b:is_bash
endif
endif
- call polyglot#ft#SetFileTypeShell("sh")
-endfunc
+ SetFileTypeShell("sh")
+enddef
-" For shell-like file types, check for an "exec" command hidden in a comment,
-" as used for Tcl.
-" Also called from scripts.vim, thus can't be local to this script.
-func polyglot#ft#SetFileTypeShell(name)
+# For shell-like file types, check for an "exec" command hidden in a comment,
+# as used for Tcl.
+# Also called from scripts.vim, thus can't be local to this script.
+export def SetFileTypeShell(name: string)
if did_filetype()
- " Filetype was already detected
+ # Filetype was already detected
return
endif
if expand("<amatch>") =~ g:ft_ignore_pat
return
endif
- let l = 2
+ var l = 2
while l < 20 && l < line("$") && getline(l) =~ '^\s*\(#\|$\)'
- " Skip empty and comment lines.
- let l = l + 1
+ # Skip empty and comment lines.
+ l += 1
endwhile
if l < line("$") && getline(l) =~ '\s*exec\s' && getline(l - 1) =~ '^\s*#.*\\$'
- " Found an "exec" line after a comment with continuation
- let n = substitute(getline(l),'\s*exec\s\+\([^ ]*/\)\=', '', '')
+ # Found an "exec" line after a comment with continuation
+ var n = substitute(getline(l), '\s*exec\s\+\([^ ]*/\)\=', '', '')
if n =~ '\<tclsh\|\<wish'
setf tcl
return
endif
endif
- exe "setf " . a:name
-endfunc
+ exe "setf " .. name
+enddef
-func polyglot#ft#CSH()
+export def CSH()
if did_filetype()
- " Filetype was already detected
+ # Filetype was already detected
return
endif
if exists("g:filetype_csh")
- call polyglot#ft#SetFileTypeShell(g:filetype_csh)
+ SetFileTypeShell(g:filetype_csh)
elseif &shell =~ "tcsh"
- call polyglot#ft#SetFileTypeShell("tcsh")
+ SetFileTypeShell("tcsh")
else
- call polyglot#ft#SetFileTypeShell("csh")
+ SetFileTypeShell("csh")
endif
-endfunc
+enddef
-let s:ft_rules_udev_rules_pattern = '^\s*\cudev_rules\s*=\s*"\([^"]\{-1,}\)/*".*'
-func polyglot#ft#FTRules()
- let path = expand('<amatch>:p')
+var ft_rules_udev_rules_pattern = '^\s*\cudev_rules\s*=\s*"\([^"]\{-1,}\)/*".*'
+export def FTRules()
+ var path = expand('<amatch>:p')
if path =~ '/\(etc/udev/\%(rules\.d/\)\=.*\.rules\|\%(usr/\)\=lib/udev/\%(rules\.d/\)\=.*\.rules\)$'
setf udevrules
return
endif
if path =~ '^/etc/ufw/'
- setf conf " Better than hog
+ setf conf # Better than hog
return
endif
if path =~ '^/\(etc\|usr/share\)/polkit-1/rules\.d'
setf javascript
return
endif
+ var config_lines: list<string>
try
- let config_lines = readfile('/etc/udev/udev.conf')
+ config_lines = readfile('/etc/udev/udev.conf')
catch /^Vim\%((\a\+)\)\=:E484/
setf hog
return
endtry
- let dir = expand('<amatch>:p:h')
+ var dir = expand('<amatch>:p:h')
for line in config_lines
if line =~ s:ft_rules_udev_rules_pattern
- let udev_rules = substitute(line, s:ft_rules_udev_rules_pattern, '\1', "")
+ var udev_rules = substitute(line, s:ft_rules_udev_rules_pattern, '\1', "")
if dir == udev_rules
setf udevrules
endif
@@ -664,24 +694,24 @@ func polyglot#ft#FTRules()
endif
endfor
setf hog
-endfunc
+enddef
-func polyglot#ft#SQL()
+export def SQL()
if exists("g:filetype_sql")
- exe "setf " . g:filetype_sql
+ exe "setf " .. g:filetype_sql
else
setf sql
endif
-endfunc
+enddef
-" If the file has an extension of 't' and is in a directory 't' or 'xt' then
-" it is almost certainly a Perl test file.
-" If the first line starts with '#' and contains 'perl' it's probably a Perl
-" file.
-" (Slow test) If a file contains a 'use' statement then it is almost certainly
-" a Perl file.
-func polyglot#ft#FTperl()
- let dirname = expand("%:p:h:t")
+# If the file has an extension of 't' and is in a directory 't' or 'xt' then
+# it is almost certainly a Perl test file.
+# If the first line starts with '#' and contains 'perl' it's probably a Perl
+# file.
+# (Slow test) If a file contains a 'use' statement then it is almost certainly
+# a Perl file.
+export def FTperl(): number
+ var dirname = expand("%:p:h:t")
if expand("%:e") == 't' && (dirname == 't' || dirname == 'xt')
setf perl
return 1
@@ -690,86 +720,88 @@ func polyglot#ft#FTperl()
setf perl
return 1
endif
- let save_cursor = getpos('.')
- call cursor(1,1)
- let has_use = search('^use\s\s*\k', 'c', 30)
+ var save_cursor = getpos('.')
+ call cursor(1, 1)
+ var has_use = search('^use\s\s*\k', 'c', 30) > 0
call setpos('.', save_cursor)
if has_use
setf perl
return 1
endif
return 0
-endfunc
-
-" Choose context, plaintex, or tex (LaTeX) based on these rules:
-" 1. Check the first line of the file for "%&<format>".
-" 2. Check the first 1000 non-comment lines for LaTeX or ConTeXt keywords.
-" 3. Default to "plain" or to g:tex_flavor, can be set in user's vimrc.
-func polyglot#ft#FTtex()
- let firstline = getline(1)
+enddef
+
+# Choose context, plaintex, or tex (LaTeX) based on these rules:
+# 1. Check the first line of the file for "%&<format>".
+# 2. Check the first 1000 non-comment lines for LaTeX or ConTeXt keywords.
+# 3. Default to "plain" or to g:tex_flavor, can be set in user's vimrc.
+export def FTtex()
+ var firstline = getline(1)
+ var format: string
if firstline =~ '^%&\s*\a\+'
- let format = tolower(matchstr(firstline, '\a\+'))
- let format = substitute(format, 'pdf', '', '')
+ format = tolower(matchstr(firstline, '\a\+'))
+ format = substitute(format, 'pdf', '', '')
if format == 'tex'
- let format = 'latex'
+ format = 'latex'
elseif format == 'plaintex'
- let format = 'plain'
+ format = 'plain'
endif
elseif expand('%') =~ 'tex/context/.*/.*.tex'
- let format = 'context'
+ format = 'context'
else
- " Default value, may be changed later:
- let format = exists("g:tex_flavor") ? g:tex_flavor : 'plain'
- " Save position, go to the top of the file, find first non-comment line.
- let save_cursor = getpos('.')
- call cursor(1,1)
- let firstNC = search('^\s*[^[:space:]%]', 'c', 1000)
- if firstNC " Check the next thousand lines for a LaTeX or ConTeXt keyword.
- let lpat = 'documentclass\>\|usepackage\>\|begin{\|newcommand\>\|renewcommand\>'
- let cpat = 'start\a\+\|setup\a\+\|usemodule\|enablemode\|enableregime\|setvariables\|useencoding\|usesymbols\|stelle\a\+\|verwende\a\+\|stel\a\+\|gebruik\a\+\|usa\a\+\|imposta\a\+\|regle\a\+\|utilisemodule\>'
- let kwline = search('^\s*\\\%(' . lpat . '\)\|^\s*\\\(' . cpat . '\)',
- \ 'cnp', firstNC + 1000)
- if kwline == 1 " lpat matched
- let format = 'latex'
- elseif kwline == 2 " cpat matched
- let format = 'context'
- endif " If neither matched, keep default set above.
- " let lline = search('^\s*\\\%(' . lpat . '\)', 'cn', firstNC + 1000)
- " let cline = search('^\s*\\\%(' . cpat . '\)', 'cn', firstNC + 1000)
- " if cline > 0
- " let format = 'context'
- " endif
- " if lline > 0 && (cline == 0 || cline > lline)
- " let format = 'tex'
- " endif
- endif " firstNC
+ # Default value, may be changed later:
+ format = exists("g:tex_flavor") ? g:tex_flavor : 'plain'
+ # Save position, go to the top of the file, find first non-comment line.
+ var save_cursor = getpos('.')
+ call cursor(1, 1)
+ var firstNC = search('^\s*[^[:space:]%]', 'c', 1000)
+ if firstNC > 0
+ # Check the next thousand lines for a LaTeX or ConTeXt keyword.
+ var lpat = 'documentclass\>\|usepackage\>\|begin{\|newcommand\>\|renewcommand\>'
+ var cpat = 'start\a\+\|setup\a\+\|usemodule\|enablemode\|enableregime\|setvariables\|useencoding\|usesymbols\|stelle\a\+\|verwende\a\+\|stel\a\+\|gebruik\a\+\|usa\a\+\|imposta\a\+\|regle\a\+\|utilisemodule\>'
+ var kwline = search('^\s*\\\%(' .. lpat .. '\)\|^\s*\\\(' .. cpat .. '\)',
+ 'cnp', firstNC + 1000)
+ if kwline == 1 # lpat matched
+ format = 'latex'
+ elseif kwline == 2 # cpat matched
+ format = 'context'
+ endif # If neither matched, keep default set above.
+ # let lline = search('^\s*\\\%(' . lpat . '\)', 'cn', firstNC + 1000)
+ # let cline = search('^\s*\\\%(' . cpat . '\)', 'cn', firstNC + 1000)
+ # if cline > 0
+ # let format = 'context'
+ # endif
+ # if lline > 0 && (cline == 0 || cline > lline)
+ # let format = 'tex'
+ # endif
+ endif # firstNC
call setpos('.', save_cursor)
- endif " firstline =~ '^%&\s*\a\+'
+ endif # firstline =~ '^%&\s*\a\+'
- " Translation from formats to file types. TODO: add AMSTeX, RevTex, others?
+ # Translation from formats to file types. TODO: add AMSTeX, RevTex, others?
if format == 'plain'
setf plaintex
elseif format == 'context'
setf context
- else " probably LaTeX
+ else # probably LaTeX
setf tex
endif
return
-endfunc
+enddef
-func polyglot#ft#FTxml()
- let n = 1
+export def FTxml()
+ var n = 1
while n < 100 && n <= line("$")
- let line = getline(n)
- " DocBook 4 or DocBook 5.
- let is_docbook4 = line =~ '<!DOCTYPE.*DocBook'
- let is_docbook5 = line =~ ' xmlns="http://docbook.org/ns/docbook"'
+ var line = getline(n)
+ # DocBook 4 or DocBook 5.
+ var is_docbook4 = line =~ '<!DOCTYPE.*DocBook'
+ var is_docbook5 = line =~ ' xmlns="http://docbook.org/ns/docbook"'
if is_docbook4 || is_docbook5
- let b:docbk_type = "xml"
+ b:docbk_type = "xml"
if is_docbook5
- let b:docbk_ver = 5
+ b:docbk_ver = 5
else
- let b:docbk_ver = 4
+ b:docbk_ver = 4
endif
setf docbk
return
@@ -778,15 +810,15 @@ func polyglot#ft#FTxml()
setf xbl
return
endif
- let n += 1
+ n += 1
endwhile
setf xml
-endfunc
+enddef
-func polyglot#ft#FTy()
- let n = 1
+export def FTy()
+ var n = 1
while n < 100 && n <= line("$")
- let line = getline(n)
+ var line = getline(n)
if line =~ '^\s*%'
setf yacc
return
@@ -795,25 +827,25 @@ func polyglot#ft#FTy()
setf racc
return
endif
- let n = n + 1
+ n += 1
endwhile
setf yacc
-endfunc
+enddef
-func polyglot#ft#Redif()
- let lnum = 1
+export def Redif()
+ var lnum = 1
while lnum <= 5 && lnum < line('$')
if getline(lnum) =~ "^\ctemplate-type:"
setf redif
return
endif
- let lnum = lnum + 1
+ lnum += 1
endwhile
-endfunc
+enddef
-" This function is called for all files under */debian/patches/*, make sure not
-" to non-dep3patch files, such as README and other text files.
-func polyglot#ft#Dep3patch()
+# This function is called for all files under */debian/patches/*, make sure not
+# to non-dep3patch files, such as README and other text files.
+export def Dep3patch()
if expand('%:t') ==# 'series'
return
endif
@@ -823,12 +855,43 @@ func polyglot#ft#Dep3patch()
setf dep3patch
return
elseif ln =~# '^---'
- " end of headers found. stop processing
+ # end of headers found. stop processing
return
endif
endfor
-endfunc
+enddef
+
+# This function checks the first 15 lines for appearance of 'FoamFile'
+# and then 'object' in a following line.
+# In that case, it's probably an OpenFOAM file
+export def FTfoam()
+ var ffile = 0
+ var lnum = 1
+ while lnum <= 15
+ if getline(lnum) =~# '^FoamFile'
+ ffile = 1
+ elseif ffile == 1 && getline(lnum) =~# '^\s*object'
+ setf foam
+ return
+ endif
+ lnum += 1
+ endwhile
+enddef
+
+# Determine if a *.tf file is TF mud client or terraform
+export def FTtf()
+ var numberOfLines = line('$')
+ for i in range(1, numberOfLines)
+ var currentLine = trim(getline(i))
+ var firstCharacter = currentLine[0]
+ if firstCharacter !=? ";" && firstCharacter !=? "/" && firstCharacter !=? ""
+ setf terraform
+ return
+ endif
+ endfor
+ setf tf
+enddef
+
-" Restore 'cpoptions'
-let &cpo = s:cpo_save
-unlet s:cpo_save
+# Uncomment this line to check for compilation errors early
+# defcompile
diff --git a/autoload/polyglot/init.vim b/autoload/polyglot/init.vim
index 353da7e4..edf1f2bc 100644
--- a/autoload/polyglot/init.vim
+++ b/autoload/polyglot/init.vim
@@ -1957,7 +1957,7 @@ if !has_key(g:polyglot_is_disabled, 'slim')
endif
if !has_key(g:polyglot_is_disabled, 'sh')
- au BufNewFile,BufRead *.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh,*.sh.in,*.tmux,*.tool,*/etc/udev/cdsymlinks.conf,{.,}bash_aliases,{.,}bash_history,{.,}bash_logout,{.,}bash_profile,{.,}bashrc,{.,}cshrc,{.,}env,{.,}env.example,{.,}flaskenv,{.,}kshrc,{.,}login,{.,}profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile setf sh
+ au BufNewFile,BufRead *.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh,*.sh.in,*.tmux,*.tool,*.zsh-theme,*/etc/udev/cdsymlinks.conf,{.,}bash_aliases,{.,}bash_history,{.,}bash_logout,{.,}bash_profile,{.,}bashrc,{.,}cshrc,{.,}env,{.,}env.example,{.,}flaskenv,{.,}kshrc,{.,}login,{.,}profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile setf sh
au BufNewFile,BufRead *.zsh,*/etc/zprofile,{.,}zfbfmarks,{.,}zlogin,{.,}zlogout,{.,}zprofile,{.,}zshenv,{.,}zshrc setf zsh
au BufNewFile,BufRead .zsh* call s:StarSetf('zsh')
au BufNewFile,BufRead .zlog* call s:StarSetf('zsh')
@@ -1985,7 +1985,7 @@ if !has_key(g:polyglot_is_disabled, 'rspec')
endif
if !has_key(g:polyglot_is_disabled, 'ruby')
- au BufNewFile,BufRead *.axlsx,*.builder,*.cap,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.opal,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rant,*.rb,*.rbi,*.rbuild,*.rbw,*.rbx,*.rjs,*.ru,*.ruby,*.rxml,*.spec,*.thor,*.watchr,{.,}Brewfile,{.,}Guardfile,{.,}autotest,{.,}irbrc,{.,}pryrc,{.,}simplecov,Appraisals,Berksfile,Buildfile,Capfile,Cheffile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,KitchenSink,Mavenfile,Podfile,Puppetfile,Rakefile,Routefile,Snapfile,Thorfile,Vagrantfile,[Rr]antfile,buildfile,vagrantfile setf ruby
+ au BufNewFile,BufRead *.axlsx,*.builder,*.cap,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.opal,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rant,*.rb,*.rbi,*.rbuild,*.rbw,*.rbx,*.rjs,*.ru,*.ruby,*.rxml,*.spec,*.thor,*.watchr,{.,}Brewfile,{.,}Guardfile,{.,}autotest,{.,}irbrc,{.,}pryrc,{.,}simplecov,Appraisals,Berksfile,Buildfile,Capfile,Cheffile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,KitchenSink,Mavenfile,Podfile,Puppetfile,Rakefile,Routefile,Snapfile,Steepfile,Thorfile,Vagrantfile,[Rr]antfile,buildfile,vagrantfile setf ruby
au BufNewFile,BufRead [Rr]akefile* call s:StarSetf('ruby')
au BufNewFile,BufRead *.erb,*.erb.deface,*.rhtml setf eruby
endif
@@ -2577,7 +2577,7 @@ if !has_key(g:polyglot_is_disabled, 'ant')
endif
if !has_key(g:polyglot_is_disabled, 'xml')
- au BufNewFile,BufRead *.adml,*.admx,*.ant,*.axml,*.builds,*.ccproj,*.ccxml,*.cdxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.csproj.user,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.tpm,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wpl,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*/etc/blkid.tab,*/etc/blkid.tab.old,*/etc/xdg/menus/*.menu,*fglrxrc,{.,}classpath,{.,}cproject,{.,}project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config setf xml
+ au BufNewFile,BufRead *.adml,*.admx,*.ant,*.axaml,*.axml,*.builds,*.ccproj,*.ccxml,*.cdxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.csproj.user,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.tpm,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wpl,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*/etc/blkid.tab,*/etc/blkid.tab.old,*/etc/xdg/menus/*.menu,*fglrxrc,{.,}classpath,{.,}cproject,{.,}project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config setf xml
endif
if !has_key(g:polyglot_is_disabled, 'csv')
diff --git a/autoload/polyglot/sleuth.vim b/autoload/polyglot/sleuth.vim
index 9e943079..c031c157 100644
--- a/autoload/polyglot/sleuth.vim
+++ b/autoload/polyglot/sleuth.vim
@@ -460,7 +460,7 @@ let s:globs = {
\ 'rrst': '*.rrst,*.srst',
\ 'rst': '*.rst,*.rest,*.rest.txt,*.rst.txt',
\ 'rtf': '*.rtf',
- \ 'ruby': '*.rb,*.builder,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rbi,*.rbuild,*.rbw,*.rbx,*.ru,*.ruby,*.spec,*.thor,*.watchr,*.rxml,*.rjs,*.rant,*.axlsx,*.cap,*.opal,.irbrc,.pryrc,.simplecov,Appraisals,Berksfile,Buildfile,Capfile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,Mavenfile,Podfile,Puppetfile,Rakefile,Snapfile,Thorfile,Vagrantfile,buildfile,[Rr]antfile,.autotest,Cheffile,KitchenSink,Routefile,.Guardfile,.Brewfile,vagrantfile,[Rr]akefile*,*_spec.rb',
+ \ 'ruby': '*.rb,*.builder,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rbi,*.rbuild,*.rbw,*.rbx,*.ru,*.ruby,*.spec,*.thor,*.watchr,*.rxml,*.rjs,*.rant,*.axlsx,*.cap,*.opal,.irbrc,.pryrc,.simplecov,Appraisals,Berksfile,Buildfile,Capfile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,Mavenfile,Podfile,Puppetfile,Rakefile,Snapfile,Steepfile,Thorfile,Vagrantfile,buildfile,[Rr]antfile,.autotest,Cheffile,KitchenSink,Routefile,.Guardfile,.Brewfile,vagrantfile,[Rr]akefile*,*_spec.rb',
\ 'rust': '*.rs,*.rs.in',
\ 'samba': 'smb.conf',
\ 'sas': '*.sas',
@@ -480,7 +480,7 @@ let s:globs = {
\ 'services': '',
\ 'setserial': '',
\ 'sexplib': '*.sexp',
- \ 'sh': '*.sh,*.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh.in,*.tmux,*.tool,.bash_aliases,.bash_history,.bash_logout,.bash_profile,.bashrc,.cshrc,.env,.env.example,.flaskenv,.kshrc,.login,.profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile',
+ \ 'sh': '*.sh,*.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh.in,*.tmux,*.tool,*.zsh-theme,.bash_aliases,.bash_history,.bash_logout,.bash_profile,.bashrc,.cshrc,.env,.env.example,.flaskenv,.kshrc,.login,.profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile',
\ 'sieve': '*.siv,*.sieve',
\ 'sil': '*.sil',
\ 'simula': '*.sim',
@@ -611,7 +611,7 @@ let s:globs = {
\ 'xhtml': '*.xhtml,*.xht',
\ 'xinetd': '',
\ 'xmath': '*.msc,*.msf',
- \ 'xml': '*.xml,*.adml,*.admx,*.ant,*.axml,*.builds,*.ccproj,*.ccxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*.cdxml,*.tpm,*.csproj.user,*.wpl,.classpath,.cproject,.project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config,*fglrxrc',
+ \ 'xml': '*.xml,*.adml,*.admx,*.ant,*.axaml,*.axml,*.builds,*.ccproj,*.ccxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*.cdxml,*.tpm,*.csproj.user,*.wpl,.classpath,.cproject,.project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config,*fglrxrc',
\ 'xml.twig': '*.xml.twig',
\ 'xmodmap': '*Xmodmap,*xmodmap*',
\ 'xpm': '*.xpm,*.pm',
diff --git a/autoload/unison.vim b/autoload/unison.vim
index cdc2efe5..e91699f0 100644
--- a/autoload/unison.vim
+++ b/autoload/unison.vim
@@ -56,7 +56,17 @@ function! unison#Complete(findstart, base) abort
" locate the start of the word
let line = getline('.')
let start = col('.') - 1
- while start > 0 && line[start - 1] !~ '\s' && line[start - 1] != '(' && line[start - 1] != ')'
+ " Examples of where we want to count the start of a word:
+ "
+ " foo List.fold<cursor>
+ " ^
+ "
+ " {Abor<cursor>
+ " ^
+ "
+ " (List.fol<cursor>
+ " ^
+ while start > 0 && line[start - 1] !~ '\v\s|[(){}\[\]]'
let start -= 1
endwhile
return start
diff --git a/compiler/ocaml.vim b/compiler/ocaml.vim
index cc45414a..cad91439 100644
--- a/compiler/ocaml.vim
+++ b/compiler/ocaml.vim
@@ -7,6 +7,7 @@ endif
" Maintainer: Markus Mottl <markus.mottl@gmail.com>
" URL: https://github.com/ocaml/vim-ocaml
" Last Change:
+" 2021 Nov 03 - Improved error format (Jules Aguillon)
" 2020 Mar 28 - Improved error format (Thomas Leonard)
" 2017 Nov 26 - Improved error format (Markus Mottl)
" 2013 Aug 27 - Added a new OCaml error format (Markus Mottl)
@@ -39,10 +40,13 @@ CompilerSet errorformat =
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d\ %.%#,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m,
+ \%EFile\ \"%f\"\\,\ line\ %l:,
\%+EReference\ to\ unbound\ regexp\ name\ %m,
\%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m,
\%Wocamlyacc:\ w\ -\ %m,
\%-Zmake%.%#,
+ \%C%*\\d\ \|%.%#,
+ \%C%p^%#,
\%C%m,
\%D%*\\a[%*\\d]:\ Entering\ directory\ `%f',
\%X%*\\a[%*\\d]:\ Leaving\ directory\ `%f',
@@ -54,7 +58,9 @@ CompilerSet errorformat =
\%X%*\\a:\ Leaving\ directory\ '%f',
\%DEntering\ directory\ '%f',
\%XLeaving\ directory\ '%f',
- \%DMaking\ %*\\a\ in\ %f
+ \%DMaking\ %*\\a\ in\ %f,
+ \%+G%m
+
let &cpo = s:cpo_save
unlet s:cpo_save
diff --git a/extras/filetype.vim b/extras/filetype.vim
index 4313adc2..f9f1ae75 100644
--- a/extras/filetype.vim
+++ b/extras/filetype.vim
@@ -1,7 +1,7 @@
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2021 Dec 27
+" Last Change: 2022 Jan 31
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
@@ -193,7 +193,8 @@ au BufNewFile,BufRead *.awk,*.gawk setf awk
au BufNewFile,BufRead *.mch,*.ref,*.imp setf b
" BASIC or Visual Basic
-au BufNewFile,BufRead *.bas call polyglot#ft#FTVB("basic")
+au BufNewFile,BufRead *.bas call polyglot#ft#FTbas()
+au BufNewFile,BufRead *.bi,*.bm call polyglot#ft#FTbas()
" Visual Basic Script (close to Visual Basic) or Visual Basic .NET
au BufNewFile,BufRead *.vb,*.vbs,*.dsm,*.ctl setf vb
@@ -202,7 +203,7 @@ au BufNewFile,BufRead *.vb,*.vbs,*.dsm,*.ctl setf vb
au BufNewFile,BufRead *.iba,*.ibi setf ibasic
" FreeBasic file (similar to QBasic)
-au BufNewFile,BufRead *.fb,*.bi setf freebasic
+au BufNewFile,BufRead *.fb setf freebasic
" Batch file for MSDOS.
au BufNewFile,BufRead *.bat,*.sys setf dosbatch
@@ -497,7 +498,7 @@ au BufNewFile,BufRead */debian/patches/* call polyglot#ft#Dep3patch()
" Diff files
au BufNewFile,BufRead *.diff,*.rej setf diff
au BufNewFile,BufRead *.patch
- \ if getline(1) =~ '^From [0-9a-f]\{40\} Mon Sep 17 00:00:00 2001$' |
+ \ if getline(1) =~# '^From [0-9a-f]\{40,\} Mon Sep 17 00:00:00 2001$' |
\ setf gitsendemail |
\ else |
\ setf diff |
@@ -653,6 +654,9 @@ au BufNewFile,BufRead *.fsl setf framescript
" FStab
au BufNewFile,BufRead fstab,mtab setf fstab
+" Fusion
+au BufRead,BufNewFile *.fusion setf fusion
+
" F# or Forth
au BufNewFile,BufRead *.fs call polyglot#ft#FTfs()
@@ -665,6 +669,12 @@ au BufNewFile,BufRead .gdbinit,gdbinit setf gdb
" GDMO
au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
+" GDscript
+au BufNewFile,BufRead *.gd setf gdscript
+
+" Godot resource
+au BufRead,BufNewFile *.tscn,*.tres setf gdresource
+
" Gedcom
au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom
@@ -676,26 +686,28 @@ autocmd BufRead,BufNewFile *.gift setf gift
" Git
au BufNewFile,BufRead COMMIT_EDITMSG,MERGE_MSG,TAG_EDITMSG setf gitcommit
-au BufNewFile,BufRead *.git/config,.gitconfig,/etc/gitconfig setf gitconfig
+au BufNewFile,BufRead NOTES_EDITMSG,EDIT_DESCRIPTION setf gitcommit
+au BufNewFile,BufRead *.git/config,.gitconfig,*/etc/gitconfig setf gitconfig
au BufNewFile,BufRead */.config/git/config setf gitconfig
+au BufNewFile,BufRead *.git/config.worktree setf gitconfig
+au BufNewFile,BufRead *.git/worktrees/*/config.worktree setf gitconfig
au BufNewFile,BufRead .gitmodules,*.git/modules/*/config setf gitconfig
if !empty($XDG_CONFIG_HOME)
au BufNewFile,BufRead $XDG_CONFIG_HOME/git/config setf gitconfig
endif
au BufNewFile,BufRead git-rebase-todo setf gitrebase
au BufRead,BufNewFile .gitsendemail.msg.?????? setf gitsendemail
-au BufNewFile,BufRead .msg.[0-9]*
- \ if getline(1) =~ '^From.*# This line is ignored.$' |
- \ setf gitsendemail |
- \ endif
au BufNewFile,BufRead *.git/*
- \ if getline(1) =~ '^\x\{40\}\>\|^ref: ' |
+ \ if getline(1) =~# '^\x\{40,\}\>\|^ref: ' |
\ setf git |
\ endif
" Gkrellmrc
au BufNewFile,BufRead gkrellmrc,gkrellmrc_? setf gkrellmrc
+" GLSL
+au BufNewFile,BufRead *.glsl setf glsl
+
" GP scripts (2.0 and onward)
au BufNewFile,BufRead *.gp,.gprc setf gp
@@ -716,15 +728,19 @@ au BufNewFile,BufRead gitolite.conf setf gitolite
au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl
" Gnuplot scripts
-au BufNewFile,BufRead *.gpi setf gnuplot
+au BufNewFile,BufRead *.gpi,.gnuplot setf gnuplot
" Go (Google)
au BufNewFile,BufRead *.go setf go
au BufNewFile,BufRead Gopkg.lock setf toml
+au BufRead,BufNewFile go.work setf gowork
" GrADS scripts
au BufNewFile,BufRead *.gs setf grads
+" GraphQL
+au BufNewFile,BufRead *.graphql,*.graphqls,*.gql setf graphql
+
" Gretl
au BufNewFile,BufRead *.gretl setf gretl
@@ -740,12 +756,18 @@ au BufNewFile,BufRead */etc/group,*/etc/group-,*/etc/group.edit,*/etc/gshadow,*/
" GTK RC
au BufNewFile,BufRead .gtkrc,gtkrc setf gtkrc
+" Hack
+au BufRead,BufNewFile *.hack,*.hackpartial setf hack
+
" Haml
au BufNewFile,BufRead *.haml setf haml
" Hamster Classic | Playground files
au BufNewFile,BufRead *.hsm setf hamster
+" Handlebars
+au BufNewFile,BufRead *.hbs setf handlebars
+
" Haskell
au BufNewFile,BufRead *.hs,*.hsc,*.hs-boot,*.hsig setf haskell
au BufNewFile,BufRead *.lhs setf lhaskell
@@ -758,12 +780,21 @@ au BufNewFile,BufRead cabal.config setf cabalconfig
au BufNewFile,BufRead *.ht setf haste
au BufNewFile,BufRead *.htpp setf hastepreproc
+" HCL
+au BufRead,BufNewFile *.hcl setf hcl
+
" Hercules
au BufNewFile,BufRead *.vc,*.ev,*.sum,*.errsum setf hercules
+" HEEx
+au BufRead,BufNewFile *.heex setf heex
+
" HEX (Intel)
au BufNewFile,BufRead *.hex,*.h32 setf hex
+" Hjson
+au BufNewFile,BufRead *.hjson setf hjson
+
" Hollywood
au BufRead,BufNewFile *.hws setf hollywood
@@ -888,6 +919,9 @@ au BufNewFile,BufRead *.jov,*.j73,*.jovial setf jovial
" JSON
au BufNewFile,BufRead *.json,*.jsonp,*.webmanifest setf json
+" JSON5
+au BufNewFile,BufRead *.json5 setf json5
+
" JSON Patch (RFC 6902)
au BufNewFile,BufRead *.json-patch setf json
@@ -939,6 +973,9 @@ au BufNewFile,BufRead *.ldif setf ldif
" Ld loader
au BufNewFile,BufRead *.ld setf ld
+" Ledger
+au BufRead,BufNewFile *.ldg,*.ledger,*.journal setf ledger
+
" Less
au BufNewFile,BufRead *.less setf less
@@ -1176,6 +1213,9 @@ au BufNewFile,BufRead *.nginx,nginx*.conf,*nginx.conf,*/etc/nginx/*,*/usr/local/
" Ninja file
au BufNewFile,BufRead *.ninja setf ninja
+" Nix
+au BufRead,BufNewFile *.nix setf nix
+
" NPM RC file
au BufNewFile,BufRead npmrc,.npmrc setf dosini
@@ -1217,6 +1257,9 @@ au BufNewFile,BufRead *.xom,*.xin setf omnimark
" OPAM
au BufNewFile,BufRead opam,*.opam,*.opam.template setf opam
+" OpenFOAM
+au BufNewFile,BufRead [a-zA-Z0-9]*Dict\(.*\)\=,[a-zA-Z]*Properties\(.*\)\=,*Transport\(.*\),fvSchemes,fvSolution,fvConstrains,fvModels,*/constant/g,*/0\(\.orig\)\=/* call polyglot#ft#FTfoam()
+
" OpenROAD
au BufNewFile,BufRead *.or setf openroad
@@ -1358,6 +1401,9 @@ au BufNewFile,BufRead *printcap
au BufNewFile,BufRead *termcap
\ let b:ptcap_type = "term" | setf ptcap
+" Prisma
+au BufRead,BufNewFile *.prisma setf prisma
+
" PCCTS / ANTLR
"au BufNewFile,BufRead *.g setf antlr
au BufNewFile,BufRead *.g setf pccts
@@ -1365,6 +1411,9 @@ au BufNewFile,BufRead *.g setf pccts
" PPWizard
au BufNewFile,BufRead *.it,*.ih setf ppwiz
+" Pug
+au BufRead,BufNewFile *.pug setf pug
+
" Puppet
au BufNewFile,BufRead Puppetfile setf ruby
@@ -1430,6 +1479,9 @@ au BufNewFile,BufRead *.pyx,*.pxd setf pyrex
au BufNewFile,BufRead *.py,*.pyw,.pythonstartup,.pythonrc setf python
au BufNewFile,BufRead *.ptl,*.pyi,SConstruct setf python
+" QL
+au BufRead,BufNewFile *.ql,*.qll setf ql
+
" Radiance
au BufNewFile,BufRead *.rad,*.mat setf radiance
@@ -1495,6 +1547,9 @@ au BufNewFile,BufRead *.r,*.R call polyglot#ft#FTr()
" Remind
au BufNewFile,BufRead .reminders,*.remind,*.rem setf remind
+" ReScript
+au BufNewFile,BufRead *.res,*.resi setf rescript
+
" Resolv.conf
au BufNewFile,BufRead resolv.conf setf resolv
@@ -1778,8 +1833,8 @@ au BufNewFile,BufRead *.sqr,*.sqi setf sqr
au BufNewFile,BufRead *.nut setf squirrel
" OpenSSH configuration
-au BufNewFile,BufRead ssh_config,*/.ssh/config setf sshconfig
-au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig
+au BufNewFile,BufRead ssh_config,*/.ssh/config,*/.ssh/*.conf setf sshconfig
+au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig
" OpenSSH server configuration
au BufNewFile,BufRead sshd_config setf sshdconfig
@@ -1834,6 +1889,9 @@ au BufNewFile,BufRead */etc/sudoers,sudoers.tmp setf sudoers
" SVG (Scalable Vector Graphics)
au BufNewFile,BufRead *.svg setf svg
+" Surface
+au BufRead,BufNewFile *.sface setf surface
+
" Tads (or Nroff or Perl test file)
au BufNewFile,BufRead *.t
\ if !polyglot#ft#FTnroff() && !polyglot#ft#FTperl() | setf tads | endif
@@ -1851,6 +1909,9 @@ au BufRead,BufNewFile *.task setf taskedit
" Tcl (JACL too)
au BufNewFile,BufRead *.tcl,*.tm,*.tk,*.itcl,*.itk,*.jacl,.tclshrc,.wishrc setf tcl
+" Teal
+au BufRead,BufNewFile *.tl setf teal
+
" TealInfo
au BufNewFile,BufRead *.tli setf tli
@@ -1868,6 +1929,9 @@ au BufRead,BufNewFile *.ttl
" Terminfo
au BufNewFile,BufRead *.ti setf terminfo
+" Terraform
+au BufRead,BufNewFile *.tfvars setf terraform
+
" TeX
au BufNewFile,BufRead *.latex,*.sty,*.dtx,*.ltx,*.bbl setf tex
au BufNewFile,BufRead *.tex call polyglot#ft#FTtex()
@@ -1885,7 +1949,13 @@ au BufNewFile,BufRead texmf.cnf setf texmf
au BufNewFile,BufRead .tidyrc,tidyrc,tidy.conf setf tidy
" TF mud client
-au BufNewFile,BufRead *.tf,.tfrc,tfrc setf tf
+au BufNewFile,BufRead .tfrc,tfrc setf tf
+
+" TF mud client or terraform
+au BufNewFile,BufRead *.tf call polyglot#ft#FTtf()
+
+" TLA+
+au BufNewFile,BufRead *.tla setf tla
" tmux configuration
au BufNewFile,BufRead {.,}tmux*.conf setf tmux
@@ -1894,7 +1964,7 @@ au BufNewFile,BufRead {.,}tmux*.conf setf tmux
au BufNewFile,BufRead *.toml setf toml
" TPP - Text Presentation Program
-au BufNewFile,BufReadPost *.tpp setf tpp
+au BufNewFile,BufRead *.tpp setf tpp
" Treetop
au BufRead,BufNewFile *.treetop setf treetop
@@ -1951,6 +2021,9 @@ au BufNewFile,BufRead */.init/*.conf,*/.init/*.override setf upstart
au BufNewFile,BufRead */.config/upstart/*.conf setf upstart
au BufNewFile,BufRead */.config/upstart/*.override setf upstart
+" Vala
+au BufNewFile,BufRead *.vala setf vala
+
" Vera
au BufNewFile,BufRead *.vr,*.vri,*.vrh setf vera
@@ -1981,7 +2054,7 @@ au BufRead,BufNewFile *.hw,*.module,*.pkg
\ endif
" Visual Basic (also uses *.bas) or FORM
-au BufNewFile,BufRead *.frm call polyglot#ft#FTVB("form")
+au BufNewFile,BufRead *.frm call polyglot#ft#FTfrm()
" SaxBasic is close to Visual Basic
au BufNewFile,BufRead *.sba setf vb
@@ -2145,6 +2218,9 @@ au BufNewFile,BufRead *.raml setf raml
" yum conf (close enough to dosini)
au BufNewFile,BufRead */etc/yum.conf setf dosini
+" YANG
+au BufRead,BufNewFile *.yang setf yang
+
" Zimbu
au BufNewFile,BufRead *.zu setf zimbu
" Zimbu Templates
@@ -2284,6 +2360,9 @@ au BufNewFile,BufRead Kconfig.* call s:StarSetf('kconfig')
" Lilo: Linux loader
au BufNewFile,BufRead lilo.conf* call s:StarSetf('lilo')
+" Libsensors
+au BufNewFile,BufRead */etc/sensors.d/[^.]* call s:StarSetf('sensors')
+
" Logcheck
au BufNewFile,BufRead */etc/logcheck/*.d*/* call s:StarSetf('logcheck')
diff --git a/extras/menu.vim b/extras/menu.vim
index 5f4e395e..12924af6 100644
--- a/extras/menu.vim
+++ b/extras/menu.vim
@@ -2,7 +2,7 @@
" You can also use this as a start for your own set of menus.
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2021 Dec 22
+" Last Change: 2022 Feb 04
" Note that ":an" (short for ":anoremenu") is often used to make a menu work
" in all modes and avoid side effects from mappings defined by the user.
@@ -33,7 +33,7 @@ if exists("v:lang") || &langmenu != ""
if strlen(s:lang) > 1 && s:lang !~? '^en_us'
" When the language does not include the charset add 'encoding'
if s:lang =~ '^\a\a$\|^\a\a_\a\a$'
- let s:lang = s:lang . '.' . &enc
+ let s:lang = s:lang .. '.' .. &enc
endif
" We always use a lowercase name.
@@ -49,26 +49,26 @@ if exists("v:lang") || &langmenu != ""
" same menu file for them.
let s:lang = substitute(s:lang, 'iso_8859-15\=$', "latin1", "")
menutrans clear
- exe "runtime! lang/menu_" . s:lang . ".vim"
+ exe "runtime! lang/menu_" .. s:lang .. ".vim"
if !exists("did_menu_trans")
" There is no exact match, try matching with a wildcard added
" (e.g. find menu_de_de.iso_8859-1.vim if s:lang == de_DE).
let s:lang = substitute(s:lang, '\.[^.]*', "", "")
- exe "runtime! lang/menu_" . s:lang . "[^a-z]*vim"
+ exe "runtime! lang/menu_" .. s:lang .. "[^a-z]*vim"
if !exists("did_menu_trans") && s:lang =~ '_'
" If the language includes a region try matching without that region.
" (e.g. find menu_de.vim if s:lang == de_DE).
let langonly = substitute(s:lang, '_.*', "", "")
- exe "runtime! lang/menu_" . langonly . "[^a-z]*vim"
+ exe "runtime! lang/menu_" .. langonly .. "[^a-z]*vim"
endif
if !exists("did_menu_trans") && strlen($LANG) > 1 && s:lang !~ '^en_us'
" On windows locale names are complicated, try using $LANG, it might
" have been set by set_init_1(). But don't do this for "en" or "en_us".
" But don't match "slovak" when $LANG is "sl".
- exe "runtime! lang/menu_" . tolower($LANG) . "[^a-z]*vim"
+ exe "runtime! lang/menu_" .. tolower($LANG) .. "[^a-z]*vim"
endif
endif
endif
@@ -104,19 +104,19 @@ if exists(':tlmenu')
tlnoremenu 9999.90 &Help.&About <C-W>:intro<CR>
endif
-fun! s:Helpfind()
+def s:Helpfind()
if !exists("g:menutrans_help_dialog")
- let g:menutrans_help_dialog = "Enter a command or word to find help on:\n\nPrepend i_ for Input mode commands (e.g.: i_CTRL-X)\nPrepend c_ for command-line editing commands (e.g.: c_<Del>)\nPrepend ' for an option name (e.g.: 'shiftwidth')"
+ g:menutrans_help_dialog = "Enter a command or word to find help on:\n\nPrepend i_ for Input mode commands (e.g.: i_CTRL-X)\nPrepend c_ for command-line editing commands (e.g.: c_<Del>)\nPrepend ' for an option name (e.g.: 'shiftwidth')"
endif
- let h = inputdialog(g:menutrans_help_dialog)
+ var h = inputdialog(g:menutrans_help_dialog)
if h != ""
- let v:errmsg = ""
- silent! exe "help " . h
+ v:errmsg = ""
+ silent! exe "help " .. h
if v:errmsg != ""
echo v:errmsg
endif
endif
-endfun
+enddef
" File menu
an 10.310 &File.&Open\.\.\.<Tab>:e :browse confirm e<CR>
@@ -154,16 +154,9 @@ an 10.600 &File.-SEP4- <Nop>
an 10.610 &File.Sa&ve-Exit<Tab>:wqa :confirm wqa<CR>
an 10.620 &File.E&xit<Tab>:qa :confirm qa<CR>
-func s:SelectAll()
- exe "norm! gg" . (&slm == "" ? "VG" : "gH\<C-O>G")
-endfunc
-
-func s:FnameEscape(fname)
- if exists('*fnameescape')
- return fnameescape(a:fname)
- endif
- return escape(a:fname, " \t\n*?[{`$\\%#'\"|!<")
-endfunc
+def s:SelectAll()
+ exe "norm! gg" .. (&slm == "" ? "VG" : "gH\<C-O>G")
+enddef
" Edit menu
an 20.310 &Edit.&Undo<Tab>u u
@@ -182,8 +175,8 @@ cnoremenu &Edit.&Paste<Tab>"+gP <C-R>+
if exists(':tlmenu')
tlnoremenu &Edit.&Paste<Tab>"+gP <C-W>"+
endif
-exe 'vnoremenu <script> &Edit.&Paste<Tab>"+gP ' . paste#paste_cmd['v']
-exe 'inoremenu <script> &Edit.&Paste<Tab>"+gP ' . paste#paste_cmd['i']
+exe 'vnoremenu <script> &Edit.&Paste<Tab>"+gP ' .. paste#paste_cmd['v']
+exe 'inoremenu <script> &Edit.&Paste<Tab>"+gP ' .. paste#paste_cmd['i']
nnoremenu 20.370 &Edit.Put\ &Before<Tab>[p [p
inoremenu &Edit.Put\ &Before<Tab>[p <C-O>[p
nnoremenu 20.380 &Edit.Put\ &After<Tab>]p ]p
@@ -214,32 +207,33 @@ an 20.425 &Edit.-SEP3- <Nop>
an 20.430 &Edit.Settings\ &Window :options<CR>
an 20.435 &Edit.Startup\ &Settings :call <SID>EditVimrc()<CR>
-fun! s:EditVimrc()
+def s:EditVimrc()
+ var fname: string
if $MYVIMRC != ''
- let fname = $MYVIMRC
+ fname = $MYVIMRC
elseif has("win32")
if $HOME != ''
- let fname = $HOME . "/_vimrc"
+ fname = $HOME .. "/_vimrc"
else
- let fname = $VIM . "/_vimrc"
+ fname = $VIM .. "/_vimrc"
endif
elseif has("amiga")
- let fname = "s:.vimrc"
+ fname = "s:.vimrc"
else
- let fname = $HOME . "/.vimrc"
+ fname = $HOME .. "/.vimrc"
endif
- let fname = s:FnameEscape(fname)
+ fname = fnameescape(fname)
if &mod
- exe "split " . fname
+ exe "split " .. fname
else
- exe "edit " . fname
+ exe "edit " .. fname
endif
-endfun
+enddef
-fun! s:FixFText()
- " Fix text in nameless register to be used with :promptfind.
+def s:FixFText(): string
+ # Fix text in nameless register to be used with :promptfind.
return substitute(@", "[\r\n]", '\\n', 'g')
-endfun
+enddef
" Edit/Global Settings
an 20.440.100 &Edit.&Global\ Settings.Toggle\ Pattern\ &Highlight<Tab>:set\ hls! :set hls! hls?<CR>
@@ -272,34 +266,34 @@ an <silent> 20.440.320 &Edit.&Global\ Settings.Toggle\ &Bottom\ Scrollbar :call
an <silent> 20.440.330 &Edit.&Global\ Settings.Toggle\ &Left\ Scrollbar :call <SID>ToggleGuiOption("l")<CR>
an <silent> 20.440.340 &Edit.&Global\ Settings.Toggle\ &Right\ Scrollbar :call <SID>ToggleGuiOption("r")<CR>
-fun! s:SearchP()
+def s:SearchP()
if !exists("g:menutrans_path_dialog")
- let g:menutrans_path_dialog = "Enter search path for files.\nSeparate directory names with a comma."
+ g:menutrans_path_dialog = "Enter search path for files.\nSeparate directory names with a comma."
endif
- let n = inputdialog(g:menutrans_path_dialog, substitute(&path, '\\ ', ' ', 'g'))
+ var n = inputdialog(g:menutrans_path_dialog, substitute(&path, '\\ ', ' ', 'g'))
if n != ""
- let &path = substitute(n, ' ', '\\ ', 'g')
+ &path = substitute(n, ' ', '\\ ', 'g')
endif
-endfun
+enddef
-fun! s:TagFiles()
+def s:TagFiles()
if !exists("g:menutrans_tags_dialog")
- let g:menutrans_tags_dialog = "Enter names of tag files.\nSeparate the names with a comma."
+ g:menutrans_tags_dialog = "Enter names of tag files.\nSeparate the names with a comma."
endif
- let n = inputdialog(g:menutrans_tags_dialog, substitute(&tags, '\\ ', ' ', 'g'))
+ var n = inputdialog(g:menutrans_tags_dialog, substitute(&tags, '\\ ', ' ', 'g'))
if n != ""
- let &tags = substitute(n, ' ', '\\ ', 'g')
+ &tags = substitute(n, ' ', '\\ ', 'g')
endif
-endfun
+enddef
-fun! s:ToggleGuiOption(option)
- " If a:option is already set in guioptions, then we want to remove it
- if match(&guioptions, "\\C" . a:option) > -1
- exec "set go-=" . a:option
- else
- exec "set go+=" . a:option
- endif
-endfun
+def s:ToggleGuiOption(option: string)
+ # If a:option is already set in guioptions, then we want to remove it
+ if match(&guioptions, "\\C" .. option) > -1
+ exec "set go-=" .. option
+ else
+ exec "set go+=" .. option
+ endif
+enddef
" Edit/File Settings
@@ -331,34 +325,36 @@ an 20.440.620.80 &Edit.F&ile\ Settings.Soft\ &Tabstop.8 :set sts=8 sts?<CR>
an <silent> 20.440.630 &Edit.F&ile\ Settings.Te&xt\ Width\.\.\. :call <SID>TextWidth()<CR>
an <silent> 20.440.640 &Edit.F&ile\ Settings.&File\ Format\.\.\. :call <SID>FileFormat()<CR>
-fun! s:TextWidth()
+
+def s:TextWidth()
if !exists("g:menutrans_textwidth_dialog")
- let g:menutrans_textwidth_dialog = "Enter new text width (0 to disable formatting): "
+ g:menutrans_textwidth_dialog = "Enter new text width (0 to disable formatting): "
endif
- let n = inputdialog(g:menutrans_textwidth_dialog, &tw)
+ var n = inputdialog(g:menutrans_textwidth_dialog, &tw .. '')
if n != ""
- " Remove leading zeros to avoid it being used as an octal number.
- " But keep a zero by itself.
- let tw = substitute(n, "^0*", "", "")
- let &tw = tw == '' ? 0 : tw
+ # Remove leading zeros to avoid it being used as an octal number.
+ # But keep a zero by itself.
+ var tw = substitute(n, "^0*", "", "")
+ &tw = tw == '' ? 0 : tw
endif
-endfun
+enddef
-fun! s:FileFormat()
+def s:FileFormat()
if !exists("g:menutrans_fileformat_dialog")
- let g:menutrans_fileformat_dialog = "Select format for writing the file"
+ g:menutrans_fileformat_dialog = "Select format for writing the file"
endif
if !exists("g:menutrans_fileformat_choices")
- let g:menutrans_fileformat_choices = "&Unix\n&Dos\n&Mac\n&Cancel"
+ g:menutrans_fileformat_choices = "&Unix\n&Dos\n&Mac\n&Cancel"
endif
+ var def_choice: number
if &ff == "dos"
- let def = 2
+ def_choice = 2
elseif &ff == "mac"
- let def = 3
+ def_choice = 3
else
- let def = 1
+ def_choice = 1
endif
- let n = confirm(g:menutrans_fileformat_dialog, g:menutrans_fileformat_choices, def, "Question")
+ var n = confirm(g:menutrans_fileformat_dialog, g:menutrans_fileformat_choices, def_choice, "Question")
if n == 1
set ff=unix
elseif n == 2
@@ -366,32 +362,33 @@ fun! s:FileFormat()
elseif n == 3
set ff=mac
endif
-endfun
+enddef
let s:did_setup_color_schemes = 0
" Setup the Edit.Color Scheme submenu
-func s:SetupColorSchemes() abort
+def s:SetupColorSchemes()
if s:did_setup_color_schemes
return
endif
- let s:did_setup_color_schemes = 1
+ s:did_setup_color_schemes = 1
- let n = globpath(&runtimepath, "colors/*.vim", 1, 1)
- let n += globpath(&packpath, "pack/*/start/*/colors/*.vim", 1, 1)
- let n += globpath(&packpath, "pack/*/opt/*/colors/*.vim", 1, 1)
+ var n = globpath(&runtimepath, "colors/*.vim", 1, 1)
+ n += globpath(&packpath, "pack/*/start/*/colors/*.vim", 1, 1)
+ n += globpath(&packpath, "pack/*/opt/*/colors/*.vim", 1, 1)
- " Ignore case for VMS and windows, sort on name
- let names = sort(map(n, 'substitute(v:val, "\\c.*[/\\\\:\\]]\\([^/\\\\:]*\\)\\.vim", "\\1", "")'), 1)
+ # Ignore case for VMS and windows, sort on name
+ var names = sort(map(n, 'substitute(v:val, "\\c.*[/\\\\:\\]]\\([^/\\\\:]*\\)\\.vim", "\\1", "")'), 1)
- " define all the submenu entries
- let idx = 100
+ # define all the submenu entries
+ var idx = 100
for name in names
- exe "an 20.450." . idx . ' &Edit.C&olor\ Scheme.' . name . " :colors " . name . "<CR>"
- let idx = idx + 10
+ exe "an 20.450." .. idx .. ' &Edit.C&olor\ Scheme.' .. name .. " :colors " .. name .. "<CR>"
+ idx += 10
endfor
silent! aunmenu &Edit.Show\ C&olor\ Schemes\ in\ Menu
-endfun
+enddef
+
if exists("do_no_lazyload_menus")
call s:SetupColorSchemes()
else
@@ -403,31 +400,33 @@ endif
if has("keymap")
let s:did_setup_keymaps = 0
- func s:SetupKeymaps() abort
+ def s:SetupKeymaps()
if s:did_setup_keymaps
return
endif
- let s:did_setup_keymaps = 1
+ s:did_setup_keymaps = 1
- let n = globpath(&runtimepath, "keymap/*.vim", 1, 1)
- if !empty(n)
- let idx = 100
+ var names = globpath(&runtimepath, "keymap/*.vim", 1, 1)
+ if !empty(names)
+ var idx = 100
an 20.460.90 &Edit.&Keymap.None :set keymap=<CR>
- for name in n
- " Ignore case for VMS and windows
- let name = substitute(name, '\c.*[/\\:\]]\([^/\\:_]*\)\(_[0-9a-zA-Z-]*\)\=\.vim', '\1', '')
- exe "an 20.460." . idx . ' &Edit.&Keymap.' . name . " :set keymap=" . name . "<CR>"
- let idx = idx + 10
+ for name in names
+ # Ignore case for VMS and windows
+ var mapname = substitute(name, '\c.*[/\\:\]]\([^/\\:_]*\)\(_[0-9a-zA-Z-]*\)\=\.vim', '\1', '')
+ exe "an 20.460." .. idx .. ' &Edit.&Keymap.' .. mapname .. " :set keymap=" .. mapname .. "<CR>"
+ idx += 10
endfor
endif
silent! aunmenu &Edit.Show\ &Keymaps\ in\ Menu
- endfun
+ enddef
+
if exists("do_no_lazyload_menus")
call s:SetupKeymaps()
else
an <silent> 20.460 &Edit.Show\ &Keymaps\ in\ Menu :call <SID>SetupKeymaps()<CR>
endif
endif
+
if has("win32") || has("gui_motif") || has("gui_gtk") || has("gui_kde") || has("gui_photon") || has("gui_mac")
an 20.470 &Edit.Select\ Fo&nt\.\.\. :set guifont=*<CR>
endif
@@ -445,7 +444,7 @@ an 40.300 &Tools.&Jump\ to\ This\ Tag<Tab>g^] g<C-]>
vunmenu &Tools.&Jump\ to\ This\ Tag<Tab>g^]
vnoremenu &Tools.&Jump\ to\ This\ Tag<Tab>g^] g<C-]>
an 40.310 &Tools.Jump\ &Back<Tab>^T <C-T>
-an 40.320 &Tools.Build\ &Tags\ File :exe "!" . g:ctags_command<CR>
+an 40.320 &Tools.Build\ &Tags\ File :exe "!" .. g:ctags_command<CR>
if has("folding") || has("spell")
an 40.330 &Tools.-SEP1- <Nop>
@@ -469,50 +468,47 @@ if has("spell")
an <silent> 40.335.270 &Tools.&Spelling.&Find\ More\ Languages :call <SID>SpellLang()<CR>
let s:undo_spelllang = ['aun &Tools.&Spelling.&Find\ More\ Languages']
- func s:SpellLang()
+ def s:SpellLang()
for cmd in s:undo_spelllang
- exe "silent! " . cmd
+ exe "silent! " .. cmd
endfor
- let s:undo_spelllang = []
+ s:undo_spelllang = []
- if &enc == "iso-8859-15"
- let enc = "latin1"
- else
- let enc = &enc
- endif
+ var enc = &enc == "iso-8859-15" ? "latin1" : &enc
if !exists("g:menutrans_set_lang_to")
- let g:menutrans_set_lang_to = 'Set Language to'
+ g:menutrans_set_lang_to = 'Set Language to'
endif
- let found = 0
- let s = globpath(&runtimepath, "spell/*." . enc . ".spl", 1, 1)
- if !empty(s)
- let n = 300
- for f in s
- let nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "")
+ var found = 0
+ var _nm = ''
+ var names = globpath(&runtimepath, "spell/*." .. enc .. ".spl", 1, 1)
+ if !empty(names)
+ var n = 300
+ for f in names
+ var nm = substitute(f, '.*spell[/\\]\(..\)\.[^/\\]*\.spl', '\1', "")
if nm != "en" && nm !~ '/'
- let _nm = nm
- let found += 1
- let menuname = '&Tools.&Spelling.' . escape(g:menutrans_set_lang_to, "\\. \t|") . '\ "' . nm . '"'
- exe 'an 40.335.' . n . ' ' . menuname . ' :set spl=' . nm . ' spell<CR>'
- let s:undo_spelllang += ['aun ' . menuname]
+ _nm = nm
+ found += 1
+ var menuname = '&Tools.&Spelling.' .. escape(g:menutrans_set_lang_to, "\\. \t|") .. '\ "' .. nm .. '"'
+ exe 'an 40.335.' .. n .. ' ' .. menuname .. ' :set spl=' .. nm .. ' spell<CR>'
+ s:undo_spelllang += ['aun ' .. menuname]
endif
- let n += 10
+ n += 10
endfor
endif
if found == 0
echomsg "Could not find other spell files"
elseif found == 1
- echomsg "Found spell file " . _nm
+ echomsg "Found spell file " .. _nm
else
- echomsg "Found " . found . " more spell files"
+ echomsg "Found " .. found .. " more spell files"
endif
- " Need to redo this when 'encoding' is changed.
+ # Need to redo this when 'encoding' is changed.
augroup spellmenu
au! EncodingChanged * call <SID>SpellLang()
augroup END
- endfun
+ enddef
endif
@@ -581,66 +577,67 @@ an <silent> 40.540 &Tools.Conve&rt\ Back<Tab>:%!xxd\ -r
" Use a function to do the conversion, so that it also works with 'insertmode'
" set.
-func s:XxdConv()
- let mod = &mod
+def s:XxdConv()
+ var mod = &mod
if has("vms")
- %!mc vim:xxd
+ :%!mc vim:xxd
else
- call s:XxdFind()
- exe '%!' . g:xxdprogram
+ s:XxdFind()
+ exe '%!' .. g:xxdprogram
endif
- if getline(1) =~ "^0000000:" " only if it worked
+ if getline(1) =~ "^0000000:" # only if it worked
set ft=xxd
endif
- let &mod = mod
-endfun
+ &mod = mod
+enddef
-func s:XxdBack()
- let mod = &mod
+def s:XxdBack()
+ var mod = &mod
if has("vms")
- %!mc vim:xxd -r
+ :%!mc vim:xxd -r
else
- call s:XxdFind()
- exe '%!' . g:xxdprogram . ' -r'
+ s:XxdFind()
+ exe '%!' .. g:xxdprogram .. ' -r'
endif
set ft=
doautocmd filetypedetect BufReadPost
- let &mod = mod
-endfun
+ &mod = mod
+enddef
-func s:XxdFind()
+def s:XxdFind()
if !exists("g:xxdprogram")
- " On the PC xxd may not be in the path but in the install directory
+ # On the PC xxd may not be in the path but in the install directory
if has("win32") && !executable("xxd")
- let g:xxdprogram = $VIMRUNTIME . (&shellslash ? '/' : '\') . "xxd.exe"
+ g:xxdprogram = $VIMRUNTIME .. (&shellslash ? '/' : '\') .. "xxd.exe"
if g:xxdprogram =~ ' '
- let g:xxdprogram = '"' .. g:xxdprogram .. '"'
+ g:xxdprogram = '"' .. g:xxdprogram .. '"'
endif
else
- let g:xxdprogram = "xxd"
+ g:xxdprogram = "xxd"
endif
endif
-endfun
+enddef
let s:did_setup_compilers = 0
" Setup the Tools.Compiler submenu
-func s:SetupCompilers() abort
+def s:SetupCompilers()
if s:did_setup_compilers
return
endif
- let s:did_setup_compilers = 1
-
- let n = globpath(&runtimepath, "compiler/*.vim", 1, 1)
- let idx = 100
- for name in n
- " Ignore case for VMS and windows
- let name = substitute(name, '\c.*[/\\:\]]\([^/\\:]*\)\.vim', '\1', '')
- exe "an 30.440." . idx . ' &Tools.Se&t\ Compiler.' . name . " :compiler " . name . "<CR>"
- let idx = idx + 10
+ s:did_setup_compilers = 1
+
+ var names = globpath(&runtimepath, "compiler/*.vim", 1, 1)
+ var idx = 100
+ for name in names
+ # Ignore case for VMS and windows
+ var cname = substitute(name, '\c.*[/\\:\]]\([^/\\:]*\)\.vim', '\1', '')
+ exe "an 30.440." .. idx .. ' &Tools.Se&t\ Compiler.' .. cname .. " :compiler " .. cname .. "<CR>"
+ idx += 10
endfor
silent! aunmenu &Tools.Show\ Compiler\ Se&ttings\ in\ Menu
-endfun
+enddef
+
if exists("do_no_lazyload_menus")
call s:SetupCompilers()
else
@@ -649,13 +646,13 @@ endif
" Load ColorScheme, Compiler Setting and Keymap menus when idle.
if !exists("do_no_lazyload_menus")
- func s:SetupLazyloadMenus()
- call s:SetupColorSchemes()
- call s:SetupCompilers()
+ def s:SetupLazyloadMenus()
+ s:SetupColorSchemes()
+ s:SetupCompilers()
if has("keymap")
- call s:SetupKeymaps()
+ s:SetupKeymaps()
endif
- endfunc
+ enddef
augroup SetupLazyloadMenus
au!
au CursorHold,CursorHoldI * call <SID>SetupLazyloadMenus() | au! SetupLazyloadMenus
@@ -680,135 +677,133 @@ if !exists("bmenu_priority")
endif
" invoked from a BufCreate or BufFilePost autocommand
-func s:BMAdd()
+def s:BMAdd()
if s:bmenu_wait == 0
- " when adding too many buffers, redraw in short format
+ # when adding too many buffers, redraw in short format
if s:bmenu_count == &menuitems && s:bmenu_short == 0
- call s:BMShow()
+ s:BMShow()
else
- let name = expand("<afile>")
- let num = expand("<abuf>") + 0 " add zero to convert to a number type
+ var name = expand("<afile>")
+ var num = str2nr(expand("<abuf>"))
if s:BMCanAdd(name, num)
- call <SID>BMFilename(name, num)
- let s:bmenu_count += 1
+ s:BMFilename(name, num)
+ s:bmenu_count += 1
endif
endif
endif
-endfunc
+enddef
" invoked from a BufDelete or BufFilePre autocommand
-func s:BMRemove()
+def s:BMRemove()
if s:bmenu_wait == 0
- let bufnum = expand("<abuf>")
+ var bufnum = expand("<abuf>")
if s:bmenu_items->has_key(bufnum)
- let menu_name = s:bmenu_items[bufnum]
- exe 'silent! aun &Buffers.' . menu_name
- let s:bmenu_count = s:bmenu_count - 1
+ var menu_name = s:bmenu_items[bufnum]
+ exe 'silent! aun &Buffers.' .. menu_name
+ s:bmenu_count = s:bmenu_count - 1
unlet s:bmenu_items[bufnum]
endif
endif
-endfunc
+enddef
" Return non-zero if buffer with number "name" / "num" is useful to add in the
" buffer menu.
-func s:BMCanAdd(name, num)
- " no directory or unlisted buffer
- if isdirectory(a:name) || !buflisted(a:num)
- return 0
+def s:BMCanAdd(name: string, num: number): bool
+ # no directory or unlisted buffer
+ if isdirectory(name) || !buflisted(num)
+ return false
endif
- " no name with control characters
- if a:name =~ '[\x01-\x1f]'
- return 0
+ # no name with control characters
+ if name =~ '[\x01-\x1f]'
+ return false
endif
- " no special buffer, such as terminal or popup
- let buftype = getbufvar(a:num, '&buftype')
+ # no special buffer, such as terminal or popup
+ var buftype = getbufvar(num, '&buftype')
if buftype != '' && buftype != 'nofile' && buftype != 'nowrite'
- return 0
+ return false
endif
- " only existing buffers
- return bufexists(a:num)
-endfunc
+ # only existing buffers
+ return bufexists(num)
+enddef
" Create the buffer menu (delete an existing one first).
-func s:BMShow(...)
- let s:bmenu_wait = 1
- let s:bmenu_short = 1
- let s:bmenu_count = 0
- let s:bmenu_items = {}
- "
- " get new priority, if exists
- if a:0 == 1
- let g:bmenu_priority = a:1
- endif
-
- " Remove old menu, if it exists; keep one entry to avoid a torn off menu to
- " disappear. Use try/catch to avoid setting v:errmsg
- try | unmenu &Buffers | catch | endtry
- exe 'noremenu ' . g:bmenu_priority . ".1 &Buffers.Dummy l"
- try | unmenu! &Buffers | catch | endtry
-
- " create new menu; set 'cpo' to include the <CR>
- let cpo_save = &cpo
- set cpo&vim
- exe 'an <silent> ' . g:bmenu_priority . ".2 &Buffers.&Refresh\\ menu :call <SID>BMShow()<CR>"
- exe 'an ' . g:bmenu_priority . ".4 &Buffers.&Delete :confirm bd<CR>"
- exe 'an ' . g:bmenu_priority . ".6 &Buffers.&Alternate :confirm b #<CR>"
- exe 'an ' . g:bmenu_priority . ".7 &Buffers.&Next :confirm bnext<CR>"
- exe 'an ' . g:bmenu_priority . ".8 &Buffers.&Previous :confirm bprev<CR>"
- exe 'an ' . g:bmenu_priority . ".9 &Buffers.-SEP- :"
- let &cpo = cpo_save
+def s:BMShow()
+ s:bmenu_wait = 1
+ s:bmenu_short = 1
+ s:bmenu_count = 0
+ s:bmenu_items = {}
+
+ # Remove old menu, if it exists; keep one entry to avoid a torn off menu to
+ # disappear. Use try/catch to avoid setting v:errmsg
+ try
+ unmenu &Buffers
+ catch
+ endtry
+ exe 'noremenu ' .. g:bmenu_priority .. ".1 &Buffers.Dummy l"
+ try
+ unmenu! &Buffers
+ catch
+ endtry
+
+ # create new menu
+ exe 'an <silent> ' .. g:bmenu_priority .. ".2 &Buffers.&Refresh\\ menu :call <SID>BMShow()<CR>"
+ exe 'an ' .. g:bmenu_priority .. ".4 &Buffers.&Delete :confirm bd<CR>"
+ exe 'an ' .. g:bmenu_priority .. ".6 &Buffers.&Alternate :confirm b #<CR>"
+ exe 'an ' .. g:bmenu_priority .. ".7 &Buffers.&Next :confirm bnext<CR>"
+ exe 'an ' .. g:bmenu_priority .. ".8 &Buffers.&Previous :confirm bprev<CR>"
+ exe 'an ' .. g:bmenu_priority .. ".9 &Buffers.-SEP- :"
unmenu &Buffers.Dummy
- " figure out how many buffers there are
- let buf = 1
+ # figure out how many buffers there are
+ var buf = 1
while buf <= bufnr('$')
if s:BMCanAdd(bufname(buf), buf)
- let s:bmenu_count = s:bmenu_count + 1
+ s:bmenu_count = s:bmenu_count + 1
endif
- let buf = buf + 1
+ buf += 1
endwhile
if s:bmenu_count <= &menuitems
- let s:bmenu_short = 0
+ s:bmenu_short = 0
endif
- " iterate through buffer list, adding each buffer to the menu:
- let buf = 1
+ # iterate through buffer list, adding each buffer to the menu:
+ buf = 1
while buf <= bufnr('$')
- let name = bufname(buf)
+ var name = bufname(buf)
if s:BMCanAdd(name, buf)
- call <SID>BMFilename(name, buf)
+ call s:BMFilename(name, buf)
endif
- let buf = buf + 1
+ buf += 1
endwhile
- let s:bmenu_wait = 0
+ s:bmenu_wait = 0
aug buffer_list
- au!
- au BufCreate,BufFilePost * call <SID>BMAdd()
- au BufDelete,BufFilePre * call <SID>BMRemove()
+ au!
+ au BufCreate,BufFilePost * call s:BMAdd()
+ au BufDelete,BufFilePre * call s:BMRemove()
aug END
-endfunc
+enddef
-func s:BMHash(name)
- " Make name all upper case, so that chars are between 32 and 96
- let nm = substitute(a:name, ".*", '\U\0', "")
+def s:BMHash(name: string): number
+ # Make name all upper case, so that chars are between 32 and 96
+ var nm = substitute(name, ".*", '\U\0', "")
+ var sp: number
if has("ebcdic")
- " HACK: Replace all non alphabetics with 'Z'
- " Just to make it work for now.
- let nm = substitute(nm, "[^A-Z]", 'Z', "g")
- let sp = char2nr('A') - 1
+ # HACK: Replace all non alphabetics with 'Z'
+ # Just to make it work for now.
+ nm = substitute(nm, "[^A-Z]", 'Z', "g")
+ sp = char2nr('A') - 1
else
- let sp = char2nr(' ')
+ sp = char2nr(' ')
endif
- " convert first six chars into a number for sorting:
+ # convert first six chars into a number for sorting:
return (char2nr(nm[0]) - sp) * 0x800000 + (char2nr(nm[1]) - sp) * 0x20000 + (char2nr(nm[2]) - sp) * 0x1000 + (char2nr(nm[3]) - sp) * 0x80 + (char2nr(nm[4]) - sp) * 0x20 + (char2nr(nm[5]) - sp)
-endfunc
+enddef
-func s:BMHash2(name)
- let nm = substitute(a:name, ".", '\L\0', "")
- " Not exactly right for EBCDIC...
+def s:BMHash2(name: string): string
+ var nm = substitute(name, ".", '\L\0', "")
if nm[0] < 'a' || nm[0] > 'z'
return '&others.'
elseif nm[0] <= 'd'
@@ -824,72 +819,70 @@ func s:BMHash2(name)
else
return '&u-z.'
endif
-endfunc
+enddef
" Insert a buffer name into the buffer menu.
-func s:BMFilename(name, num)
- let munge = <SID>BMMunge(a:name, a:num)
- let hash = <SID>BMHash(munge)
+def s:BMFilename(name: string, num: number)
+ var munge = s:BMMunge(name, num)
+ var hash = s:BMHash(munge)
+ var cmd: string
if s:bmenu_short == 0
- let s:bmenu_items[a:num] = munge
- let cmd = 'an ' . g:bmenu_priority . '.' . hash . ' &Buffers.' . munge
+ s:bmenu_items[num] = munge
+ cmd = 'an ' .. g:bmenu_priority .. '.' .. hash .. ' &Buffers.' .. munge
else
- let menu_name = <SID>BMHash2(munge) . munge
- let s:bmenu_items[a:num] = menu_name
- let cmd = 'an ' . g:bmenu_priority . '.' . hash . '.' . hash . ' &Buffers.' . menu_name
+ var menu_name = s:BMHash2(munge) .. munge
+ s:bmenu_items[num] = menu_name
+ cmd = 'an ' .. g:bmenu_priority .. '.' .. hash .. '.' .. hash .. ' &Buffers.' .. menu_name
endif
- " set 'cpo' to include the <CR>
- let cpo_save = &cpo
- set cpo&vim
- exe cmd . ' :confirm b' . a:num . '<CR>'
- let &cpo = cpo_save
-endfunc
+ exe cmd .. ' :confirm b' .. num .. '<CR>'
+enddef
" Truncate a long path to fit it in a menu item.
if !exists("g:bmenu_max_pathlen")
let g:bmenu_max_pathlen = 35
endif
-func s:BMTruncName(fname)
- let name = a:fname
+
+def s:BMTruncName(fname: string): string
+ var name = fname
if g:bmenu_max_pathlen < 5
- let name = ""
+ name = ""
else
- let len = strlen(name)
+ var len = strlen(name)
if len > g:bmenu_max_pathlen
- let amountl = (g:bmenu_max_pathlen / 2) - 2
- let amountr = g:bmenu_max_pathlen - amountl - 3
- let pattern = '^\(.\{,' . amountl . '}\).\{-}\(.\{,' . amountr . '}\)$'
- let left = substitute(name, pattern, '\1', '')
- let right = substitute(name, pattern, '\2', '')
+ var amountl = (g:bmenu_max_pathlen / 2) - 2
+ var amountr = g:bmenu_max_pathlen - amountl - 3
+ var pattern = '^\(.\{,' .. amountl .. '}\).\{-}\(.\{,' .. amountr .. '}\)$'
+ var left = substitute(name, pattern, '\1', '')
+ var right = substitute(name, pattern, '\2', '')
if strlen(left) + strlen(right) < len
- let name = left . '...' . right
+ name = left .. '...' .. right
endif
endif
endif
return name
-endfunc
+enddef
-func s:BMMunge(fname, bnum)
- let name = a:fname
+def s:BMMunge(fname: string, bnum: number): string
+ var name = fname
if name == ''
if !exists("g:menutrans_no_file")
- let g:menutrans_no_file = "[No Name]"
+ g:menutrans_no_file = "[No Name]"
endif
- let name = g:menutrans_no_file
+ name = g:menutrans_no_file
else
- let name = fnamemodify(name, ':p:~')
+ name = fnamemodify(name, ':p:~')
endif
- " detach file name and separate it out:
- let name2 = fnamemodify(name, ':t')
- if a:bnum >= 0
- let name2 = name2 . ' (' . a:bnum . ')'
+ # detach file name and separate it out:
+ var name2 = fnamemodify(name, ':t')
+ if bnum >= 0
+ name2 = name2 .. ' (' .. bnum .. ')'
endif
- let name = name2 . "\t" . <SID>BMTruncName(fnamemodify(name,':h'))
- let name = escape(name, "\\. \t|")
- let name = substitute(name, "&", "&&", "g")
- let name = substitute(name, "\n", "^@", "g")
+ name = name2 .. "\t" .. s:BMTruncName(fnamemodify(name, ':h'))
+ name = escape(name, "\\. \t|")
+ name = substitute(name, "&", "&&", "g")
+ name = substitute(name, "\n", "^@", "g")
return name
-endfunc
+enddef
" When just starting Vim, load the buffer menu later
if has("vim_starting")
@@ -910,13 +903,13 @@ an 70.320 &Window.Sp&lit\ To\ #<Tab>^W^^ <C-W><C-^>
an 70.330 &Window.Split\ &Vertically<Tab>^Wv <C-W>v
an <silent> 70.332 &Window.Split\ File\ E&xplorer :call MenuExplOpen()<CR>
if !exists("*MenuExplOpen")
- fun MenuExplOpen()
+ def MenuExplOpen()
if @% == ""
- 20vsp .
+ :20vsp .
else
- exe "20vsp " . s:FnameEscape(expand("%:p:h"))
+ exe ":20vsp " .. fnameescape(expand("%:p:h"))
endif
- endfun
+ enddef
endif
an 70.335 &Window.-SEP1- <Nop>
an 70.340 &Window.&Close<Tab>^Wc :confirm close<CR>
@@ -943,8 +936,8 @@ vnoremenu 1.30 PopUp.&Copy "+y
cnoremenu 1.30 PopUp.&Copy <C-Y>
nnoremenu 1.40 PopUp.&Paste "+gP
cnoremenu 1.40 PopUp.&Paste <C-R>+
-exe 'vnoremenu <script> 1.40 PopUp.&Paste ' . paste#paste_cmd['v']
-exe 'inoremenu <script> 1.40 PopUp.&Paste ' . paste#paste_cmd['i']
+exe 'vnoremenu <script> 1.40 PopUp.&Paste ' .. paste#paste_cmd['v']
+exe 'inoremenu <script> 1.40 PopUp.&Paste ' .. paste#paste_cmd['i']
vnoremenu 1.50 PopUp.&Delete x
an 1.55 PopUp.-SEP2- <Nop>
vnoremenu 1.60 PopUp.Select\ Blockwise <C-V>
@@ -986,77 +979,75 @@ cnoremenu <script> <silent> 1.100 PopUp.Select\ &All <C-U>call <SID>SelectAll()<
if has("spell")
" Spell suggestions in the popup menu. Note that this will slow down the
" appearance of the menu!
- func s:SpellPopup()
+ def s:SpellPopup()
if exists("s:changeitem") && s:changeitem != ''
- call <SID>SpellDel()
+ call s:SpellDel()
endif
- " Return quickly if spell checking is not enabled.
+ # Return quickly if spell checking is not enabled.
if !&spell || &spelllang == ''
return
endif
- let curcol = col('.')
- let [w, a] = spellbadword()
- if col('.') > curcol " don't use word after the cursor
- let w = ''
+ var curcol = col('.')
+ var w: string
+ var a: string
+ [w, a] = spellbadword()
+ if col('.') > curcol # don't use word after the cursor
+ w = ''
endif
if w != ''
if a == 'caps'
- let s:suglist = [substitute(w, '.*', '\u&', '')]
+ s:suglist = [substitute(w, '.*', '\u&', '')]
else
- let s:suglist = spellsuggest(w, 10)
+ s:suglist = spellsuggest(w, 10)
endif
if len(s:suglist) > 0
if !exists("g:menutrans_spell_change_ARG_to")
- let g:menutrans_spell_change_ARG_to = 'Change\ "%s"\ to'
+ g:menutrans_spell_change_ARG_to = 'Change\ "%s"\ to'
endif
- let s:changeitem = printf(g:menutrans_spell_change_ARG_to, escape(w, ' .'))
- let s:fromword = w
- let pri = 1
- " set 'cpo' to include the <CR>
- let cpo_save = &cpo
- set cpo&vim
+ s:changeitem = printf(g:menutrans_spell_change_ARG_to, escape(w, ' .'))
+ s:fromword = w
+ var pri = 1
for sug in s:suglist
- exe 'anoremenu 1.5.' . pri . ' PopUp.' . s:changeitem . '.' . escape(sug, ' .')
- \ . ' :call <SID>SpellReplace(' . pri . ')<CR>'
- let pri += 1
+ exe 'anoremenu 1.5.' .. pri .. ' PopUp.' .. s:changeitem .. '.' .. escape(sug, ' .')
+ \ .. ' :call <SID>SpellReplace(' .. pri .. ')<CR>'
+ pri += 1
endfor
if !exists("g:menutrans_spell_add_ARG_to_word_list")
- let g:menutrans_spell_add_ARG_to_word_list = 'Add\ "%s"\ to\ Word\ List'
+ g:menutrans_spell_add_ARG_to_word_list = 'Add\ "%s"\ to\ Word\ List'
endif
- let s:additem = printf(g:menutrans_spell_add_ARG_to_word_list, escape(w, ' .'))
- exe 'anoremenu 1.6 PopUp.' . s:additem . ' :spellgood ' . w . '<CR>'
+ s:additem = printf(g:menutrans_spell_add_ARG_to_word_list, escape(w, ' .'))
+ exe 'anoremenu 1.6 PopUp.' .. s:additem .. ' :spellgood ' .. w .. '<CR>'
if !exists("g:menutrans_spell_ignore_ARG")
- let g:menutrans_spell_ignore_ARG = 'Ignore\ "%s"'
+ g:menutrans_spell_ignore_ARG = 'Ignore\ "%s"'
endif
- let s:ignoreitem = printf(g:menutrans_spell_ignore_ARG, escape(w, ' .'))
- exe 'anoremenu 1.7 PopUp.' . s:ignoreitem . ' :spellgood! ' . w . '<CR>'
+ s:ignoreitem = printf(g:menutrans_spell_ignore_ARG, escape(w, ' .'))
+ exe 'anoremenu 1.7 PopUp.' .. s:ignoreitem .. ' :spellgood! ' .. w .. '<CR>'
anoremenu 1.8 PopUp.-SpellSep- :
- let &cpo = cpo_save
endif
endif
- call cursor(0, curcol) " put the cursor back where it was
- endfunc
+ call cursor(0, curcol) # put the cursor back where it was
+ enddef
- func s:SpellReplace(n)
- let l = getline('.')
- " Move the cursor to the start of the word.
+ def s:SpellReplace(n: number)
+ var l = getline('.')
+ # Move the cursor to the start of the word.
call spellbadword()
- call setline('.', strpart(l, 0, col('.') - 1) . s:suglist[a:n - 1]
- \ . strpart(l, col('.') + len(s:fromword) - 1))
- endfunc
-
- func s:SpellDel()
- exe "aunmenu PopUp." . s:changeitem
- exe "aunmenu PopUp." . s:additem
- exe "aunmenu PopUp." . s:ignoreitem
+ call setline('.', strpart(l, 0, col('.') - 1) .. s:suglist[n - 1]
+ \ .. strpart(l, col('.') + len(s:fromword) - 1))
+ enddef
+
+ def s:SpellDel()
+ exe "aunmenu PopUp." .. s:changeitem
+ exe "aunmenu PopUp." .. s:additem
+ exe "aunmenu PopUp." .. s:ignoreitem
aunmenu PopUp.-SpellSep-
- let s:changeitem = ''
- endfun
+ s:changeitem = ''
+ enddef
augroup SpellPopupMenu
au! MenuPopup * call <SID>SpellPopup()
@@ -1089,8 +1080,8 @@ if has("toolbar")
cnoremenu 1.80 ToolBar.Copy <C-Y>
nnoremenu 1.90 ToolBar.Paste "+gP
cnoremenu ToolBar.Paste <C-R>+
- exe 'vnoremenu <script> ToolBar.Paste ' . paste#paste_cmd['v']
- exe 'inoremenu <script> ToolBar.Paste ' . paste#paste_cmd['i']
+ exe 'vnoremenu <script> ToolBar.Paste ' .. paste#paste_cmd['v']
+ exe 'inoremenu <script> ToolBar.Paste ' .. paste#paste_cmd['i']
if !has("gui_athena")
an 1.95 ToolBar.-sep3- <Nop>
@@ -1108,7 +1099,7 @@ if has("toolbar")
an 1.245 ToolBar.-sep6- <Nop>
an 1.250 ToolBar.Make :make<CR>
- an 1.270 ToolBar.RunCtags :exe "!" . g:ctags_command<CR>
+ an 1.270 ToolBar.RunCtags :exe "!" .. g:ctags_command<CR>
an 1.280 ToolBar.TagJump g<C-]>
an 1.295 ToolBar.-sep7- <Nop>
@@ -1145,22 +1136,23 @@ else
endif
" Select a session to load; default to current session name if present
-fun! s:LoadVimSesn()
+def s:LoadVimSesn()
+ var name: string
if strlen(v:this_session) > 0
- let name = s:FnameEscape(v:this_session)
+ name = fnameescape(v:this_session)
else
- let name = "Session.vim"
+ name = "Session.vim"
endif
- execute "browse so " . name
-endfun
+ execute "browse so " .. name
+enddef
" Select a session to save; default to current session name if present
-fun! s:SaveVimSesn()
+def s:SaveVimSesn()
if strlen(v:this_session) == 0
- let v:this_session = "Session.vim"
+ v:this_session = "Session.vim"
endif
- execute "browse mksession! " . s:FnameEscape(v:this_session)
-endfun
+ execute "browse mksession! " .. fnameescape(v:this_session)
+enddef
endif
@@ -1173,7 +1165,7 @@ if !exists("did_install_syntax_menu")
an 50.214 &Syntax.A&utomatic :syn on<CR>
an <silent> 50.216 &Syntax.On/Off\ for\ &This\ File :call <SID>SynOnOff()<CR>
if !exists("*s:SynOnOff")
- fun s:SynOnOff()
+ def s:SynOnOff()
if has("syntax_items")
syn clear
else
@@ -1182,7 +1174,7 @@ if !exists("did_install_syntax_menu")
endif
set syn=ON
endif
- endfun
+ enddef
endif
endif
@@ -1209,6 +1201,9 @@ an 50.710 &Syntax.Co&lor\ Test :sp $VIMRUNTIME/syntax/colortest.vim<Bar>so %<CR
an 50.720 &Syntax.&Highlight\ Test :runtime syntax/hitest.vim<CR>
an 50.730 &Syntax.&Convert\ to\ HTML :runtime syntax/2html.vim<CR>
+" Uncomment the next line to compile the functions early to find any mistakes
+" defcompile
+
endif " !exists("did_install_syntax_menu")
" Restore the previous value of 'cpoptions'.
diff --git a/ftplugin/basic.vim b/ftplugin/basic.vim
index 016253f6..1702fbd6 100644
--- a/ftplugin/basic.vim
+++ b/ftplugin/basic.vim
@@ -3,9 +3,9 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'ftplugin/basic.vim')
endif
" Vim filetype plugin file
-" Language: BASIC
+" Language: BASIC (QuickBASIC 4.5)
" Maintainer: Doug Kearns <dougkearns@gmail.com>
-" Last Change: 2015 Jan 10
+" Last Change: 2021 Mar 16
if exists("b:did_ftplugin")
finish
@@ -15,17 +15,46 @@ let b:did_ftplugin = 1
let s:cpo_save = &cpo
set cpo&vim
-setlocal comments=:REM,:'
+setlocal comments=:REM\ ,:Rem\ ,:rem\ ,:'
setlocal commentstring='\ %s
setlocal formatoptions-=t formatoptions+=croql
+" TODO: support exit ... as middle matches?
+if exists("loaded_matchit") && !exists("b:match_words")
+ let s:line_start = '\%(^\s*\)\@<='
+ let s:not_end = '\%(end\s\+\)\@<!'
+ let s:not_end_or_exit = '\%(\%(end\|exit\)\s\+\)\@<!'
+
+ let b:match_ignorecase = 1
+ let b:match_words =
+ \ s:not_end_or_exit .. '\<def\s\+fn:\<end\s\+def\>,' ..
+ \ s:not_end_or_exit .. '\<function\>:\<end\s\+function\>,' ..
+ \ s:not_end_or_exit .. '\<sub\>:\<end\s\+sub\>,' ..
+ \ s:not_end .. '\<type\>:\<end\s\+type\>,' ..
+ \ s:not_end .. '\<select\>:\%(select\s\+\)\@<!\<case\%(\s\+\%(else\|is\)\)\=\>:\<end\s\+select\>,' ..
+ \ '\<do\>:\<loop\>,' ..
+ \ '\<for\>\%(\s\+\%(input\|output\|random\|append\|binary\)\)\@!:\<next\>,' ..
+ \ '\<while\>:\<wend\>,' ..
+ \ s:line_start .. 'if\%(.*\<then\s*\%($\|''\)\)\@=:\<\%(' .. s:line_start .. 'else\|elseif\)\>:\<end\s\+if\>,' ..
+ \ '\<lock\>:\<unlock\>'
+
+ let b:match_skip = 'synIDattr(synID(line("."),col("."),1),"name") =~? "comment\\|string" || ' ..
+ \ 'strpart(getline("."), 0, col(".") ) =~? "\\<exit\\s\\+"'
+
+ unlet s:line_start s:not_end s:not_end_or_exit
+endif
+
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
- let b:browsefilter = "BASIC Source Files (*.bas)\t*.bas\n" .
- \ "All Files (*.*)\t*.*\n"
+ let b:browsefilter = "BASIC Source Files (*.bas)\t*.bas\n" ..
+ \ "BASIC Include Files (*.bi, *.bm)\t*.bi;*.bm\n" ..
+ \ "All Files (*.*)\t*.*\n"
endif
-let b:undo_ftplugin = "setl fo< com< cms< sua<" .
- \ " | unlet! b:browsefilter"
+let b:undo_ftplugin = "setl fo< com< cms<" ..
+ \ " | unlet! b:match_ignorecase b:match_skip b:match_words" ..
+ \ " | unlet! b:browsefilter"
let &cpo = s:cpo_save
unlet s:cpo_save
+
+" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:
diff --git a/ftplugin/freebasic.vim b/ftplugin/freebasic.vim
index d2212481..41aa2d30 100644
--- a/ftplugin/freebasic.vim
+++ b/ftplugin/freebasic.vim
@@ -3,15 +3,67 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'ftplugin/freebas
endif
" Vim filetype plugin file
-" Language: FreeBasic
+" Language: FreeBASIC
" Maintainer: Doug Kearns <dougkearns@gmail.com>
-" Last Change: 2015 Jan 10
+" Last Change: 2021 Mar 16
+" Setup {{{1
if exists("b:did_ftplugin")
finish
endif
-let b:did_ftplugin = 1
+
+let s:cpo_save = &cpo
+set cpo&vim
runtime! ftplugin/basic.vim
-" vim: ts=8
+let s:dialect = freebasic#GetDialect()
+
+" Comments {{{1
+" add ''comments before 'comments
+let &l:comments = "sO:*\ -,mO:*\ \ ,exO:*/,s1:/',mb:',ex:'/,:''," .. &l:comments
+
+" Match words {{{1
+if exists("loaded_matchit")
+ let s:not_end = '\%(end\s\+\)\@<!'
+
+ let b:match_words .= ','
+
+ if s:dialect == 'fb'
+ let b:match_words .= s:not_end .. '\<constructor\>:\<end\s\+constructor\>,' ..
+ \ s:not_end .. '\<destructor\>:\<end\s\+destructor\>,' ..
+ \ s:not_end .. '\<property\>:\<end\s\+property\>,' ..
+ \ s:not_end .. '\<operator\>:\<end\s\+operator\>,' ..
+ \ s:not_end .. '\<extern\%(\s\+"\)\@=:\<end\s\+extern\>,'
+ endif
+
+ if s:dialect == 'fb' || s:dialect == 'deprecated'
+ let b:match_words .= s:not_end .. '\<scope\>:\<end\s\+scope\>,'
+ endif
+
+ if s:dialect == 'qb'
+ let b:match_words .= s:not_end .. '\<__asm\>:\<end\s\+__asm\>,' ..
+ \ s:not_end .. '\<__union\>:\<end\s\+__union\>,' ..
+ \ s:not_end .. '\<__with\>:\<end\s\+__with\>,'
+ else
+ let b:match_words .= s:not_end .. '\<asm\>:\<end\s\+asm\>,' ..
+ \ s:not_end .. '\<namespace\>:\<end\s\+namespace\>,' ..
+ \ s:not_end .. '\<union\>:\<end\s\+union\>,' ..
+ \ s:not_end .. '\<with\>:\<end\s\+with\>,'
+ endif
+
+ let b:match_words .= s:not_end .. '\<enum\>:\<end\s\+enum\>,' ..
+ \ '^#\s*\%(if\|ifdef\|ifndef\)\>:^#\s*\%(else\|elseif\)\>:^#\s*endif\>,' ..
+ \ '^#\s*macro\>:^#\s*endmacro\>'
+
+ " skip "function = <retval>"
+ let b:match_skip .= '|| strpart(getline("."), col(".") - 1) =~? "^\\<function\\s\\+="'
+
+ unlet s:not_end
+endif
+
+" Cleanup {{{1
+let &cpo = s:cpo_save
+unlet s:cpo_save
+
+" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:
diff --git a/ftplugin/markdown.vim b/ftplugin/markdown.vim
index cb5edc8d..7ed65fe8 100644
--- a/ftplugin/markdown.vim
+++ b/ftplugin/markdown.vim
@@ -98,7 +98,7 @@ endfunction
"
function! s:MoveToCurHeader()
let l:lineNum = s:GetHeaderLineNum()
- if l:lineNum != 0
+ if l:lineNum !=# 0
call cursor(l:lineNum, 1)
else
echo 'outside any header'
@@ -151,7 +151,7 @@ function! s:GetHeaderLevel(...)
let l:line = a:1
endif
let l:linenum = s:GetHeaderLineNum(l:line)
- if l:linenum != 0
+ if l:linenum !=# 0
return s:GetLevelOfHeaderAtLine(l:linenum)
else
return 0
@@ -165,13 +165,13 @@ function! s:GetHeaderList()
let l:fenced_block = 0
let l:front_matter = 0
let l:header_list = []
- let l:vim_markdown_frontmatter = get(g:, "vim_markdown_frontmatter", 0)
+ let l:vim_markdown_frontmatter = get(g:, 'vim_markdown_frontmatter', 0)
for i in range(1, line('$'))
let l:lineraw = getline(i)
let l:l1 = getline(i+1)
- let l:line = substitute(l:lineraw, "#", "\\\#", "g")
+ let l:line = substitute(l:lineraw, '#', "\\\#", 'g')
" exclude lines in fenced code blocks
- if l:line =~ '````*' || l:line =~ '\~\~\~\~*'
+ if l:line =~# '````*' || l:line =~# '\~\~\~\~*'
if l:fenced_block == 0
let l:fenced_block = 1
elseif l:fenced_block == 1
@@ -180,24 +180,24 @@ function! s:GetHeaderList()
" exclude lines in frontmatters
elseif l:vim_markdown_frontmatter == 1
if l:front_matter == 1
- if l:line == '---'
+ if l:line ==# '---'
let l:front_matter = 0
endif
elseif i == 1
- if l:line == '---'
+ if l:line ==# '---'
let l:front_matter = 1
endif
endif
endif
" match line against header regex
- if join(getline(i, i + 1), "\n") =~ s:headersRegexp && l:line =~ '^\S'
+ if join(getline(i, i + 1), "\n") =~# s:headersRegexp && l:line =~# '^\S'
let l:is_header = 1
else
let l:is_header = 0
endif
- if l:is_header == 1 && l:fenced_block == 0 && l:front_matter == 0
+ if l:is_header ==# 1 && l:fenced_block ==# 0 && l:front_matter ==# 0
" remove hashes from atx headers
- if match(l:line, "^#") > -1
+ if match(l:line, '^#') > -1
let l:line = substitute(l:line, '\v^#*[ ]*', '', '')
let l:line = substitute(l:line, '\v[ ]*#*$', '', '')
endif
@@ -365,11 +365,11 @@ function! s:Toc(...)
let l:header_list = s:GetHeaderList()
let l:indented_header_list = []
if len(l:header_list) == 0
- echom "Toc: No headers."
+ echom 'Toc: No headers.'
return
endif
let l:header_max_len = 0
- let l:vim_markdown_toc_autofit = get(g:, "vim_markdown_toc_autofit", 0)
+ let l:vim_markdown_toc_autofit = get(g:, 'vim_markdown_toc_autofit', 0)
for h in l:header_list
" set header number of the cursor position
if l:cursor_header == 0
@@ -442,7 +442,7 @@ function! s:InsertToc(format, ...)
let l:toc = []
let l:header_list = s:GetHeaderList()
if len(l:header_list) == 0
- echom "InsertToc: No headers."
+ echom 'InsertToc: No headers.'
return
endif
@@ -554,7 +554,7 @@ function! s:TableFormat()
" Move colons for alignment to left or right side of the cell.
execute 's/:\( \+\)|/\1:|/e' . l:flags
execute 's/|\( \+\):/|:\1/e' . l:flags
- execute 's/ /-/' . l:flags
+ execute 's/|:\?\zs[ -]\+\ze:\?|/\=repeat("-", len(submatch(0)))/' . l:flags
call setpos('.', l:pos)
endfunction
@@ -657,7 +657,7 @@ endfunction
"
function! s:OpenUrlUnderCursor()
let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.'))
- if l:url != ''
+ if l:url !=# ''
call s:VersionAwareNetrwBrowseX(l:url)
else
echomsg 'The cursor is not on a link.'
@@ -668,8 +668,24 @@ endfunction
" script while this function is running. We must not replace it.
if !exists('*s:EditUrlUnderCursor')
function s:EditUrlUnderCursor()
+ let l:editmethod = ''
+ " determine how to open the linked file (split, tab, etc)
+ if exists('g:vim_markdown_edit_url_in')
+ if g:vim_markdown_edit_url_in ==# 'tab'
+ let l:editmethod = 'tabnew'
+ elseif g:vim_markdown_edit_url_in ==# 'vsplit'
+ let l:editmethod = 'vsp'
+ elseif g:vim_markdown_edit_url_in ==# 'hsplit'
+ let l:editmethod = 'sp'
+ else
+ let l:editmethod = 'edit'
+ endif
+ else
+ " default to current buffer
+ let l:editmethod = 'edit'
+ endif
let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.'))
- if l:url != ''
+ if l:url !=# ''
if get(g:, 'vim_markdown_autowrite', 0)
write
endif
@@ -679,14 +695,14 @@ if !exists('*s:EditUrlUnderCursor')
if len(l:parts) == 2
let [l:url, l:anchor] = parts
let l:anchorexpr = get(g:, 'vim_markdown_anchorexpr', '')
- if l:anchorexpr != ''
+ if l:anchorexpr !=# ''
let l:anchor = eval(substitute(
\ l:anchorexpr, 'v:anchor',
\ escape('"'.l:anchor.'"', '"'), ''))
endif
endif
endif
- if l:url != ''
+ if l:url !=# ''
let l:ext = ''
if get(g:, 'vim_markdown_no_extensions_in_markdown', 0)
" use another file extension if preferred
@@ -697,29 +713,13 @@ if !exists('*s:EditUrlUnderCursor')
endif
endif
let l:url = fnameescape(fnamemodify(expand('%:h').'/'.l:url.l:ext, ':.'))
- let l:editmethod = ''
- " determine how to open the linked file (split, tab, etc)
- if exists('g:vim_markdown_edit_url_in')
- if g:vim_markdown_edit_url_in == 'tab'
- let l:editmethod = 'tabnew'
- elseif g:vim_markdown_edit_url_in == 'vsplit'
- let l:editmethod = 'vsp'
- elseif g:vim_markdown_edit_url_in == 'hsplit'
- let l:editmethod = 'sp'
- else
- let l:editmethod = 'edit'
- endif
- else
- " default to current buffer
- let l:editmethod = 'edit'
- endif
execute l:editmethod l:url
endif
- if l:anchor != ''
+ if l:anchor !=# ''
silent! execute '/'.l:anchor
endif
else
- echomsg 'The cursor is not on a link.'
+ execute l:editmethod . ' <cfile>'
endif
endfunction
endif
@@ -754,7 +754,7 @@ if !get(g:, 'vim_markdown_no_default_key_mappings', 0)
call <sid>MapNotHasmapto('][', 'Markdown_MoveToNextSiblingHeader')
call <sid>MapNotHasmapto('[]', 'Markdown_MoveToPreviousSiblingHeader')
call <sid>MapNotHasmapto(']u', 'Markdown_MoveToParentHeader')
- call <sid>MapNotHasmapto(']c', 'Markdown_MoveToCurHeader')
+ call <sid>MapNotHasmapto(']h', 'Markdown_MoveToCurHeader')
call <sid>MapNotHasmapto('gx', 'Markdown_OpenUrlUnderCursor')
call <sid>MapNotHasmapto('ge', 'Markdown_EditUrlUnderCursor')
endif
@@ -774,8 +774,8 @@ command! -buffer -nargs=? InsertNToc call s:InsertToc('numbers', <args>)
if exists('g:vim_markdown_fenced_languages')
let s:filetype_dict = {}
for s:filetype in g:vim_markdown_fenced_languages
- let key = matchstr(s:filetype, "[^=]*")
- let val = matchstr(s:filetype, "[^=]*$")
+ let key = matchstr(s:filetype, '[^=]*')
+ let val = matchstr(s:filetype, '[^=]*$')
let s:filetype_dict[key] = val
endfor
else
@@ -793,7 +793,7 @@ function! s:MarkdownHighlightSources(force)
let filetypes = {}
for line in getline(1, '$')
let ft = matchstr(line, '```\s*\zs[0-9A-Za-z_+-]*\ze.*')
- if !empty(ft) && ft !~ '^\d*$' | let filetypes[ft] = 1 | endif
+ if !empty(ft) && ft !~# '^\d*$' | let filetypes[ft] = 1 | endif
endfor
if !exists('b:mkd_known_filetypes')
let b:mkd_known_filetypes = {}
@@ -816,7 +816,7 @@ function! s:MarkdownHighlightSources(force)
else
let filetype = ft
endif
- let group = 'mkdSnippet' . toupper(substitute(filetype, "[+-]", "_", "g"))
+ let group = 'mkdSnippet' . toupper(substitute(filetype, '[+-]', '_', 'g'))
if !has_key(b:mkd_included_filetypes, filetype)
let include = s:SyntaxInclude(filetype)
let b:mkd_included_filetypes[filetype] = 1
@@ -858,13 +858,13 @@ endfunction
function! s:MarkdownRefreshSyntax(force)
- if &filetype =~ 'markdown' && line('$') > 1
+ if &filetype =~# 'markdown' && line('$') > 1
call s:MarkdownHighlightSources(a:force)
endif
endfunction
function! s:MarkdownClearSyntaxVariables()
- if &filetype =~ 'markdown'
+ if &filetype =~# 'markdown'
unlet! b:mkd_included_filetypes
endif
endfunction
diff --git a/ftplugin/plantuml.vim b/ftplugin/plantuml.vim
index 9f525dc3..5d59c507 100644
--- a/ftplugin/plantuml.vim
+++ b/ftplugin/plantuml.vim
@@ -5,7 +5,6 @@ endif
scriptencoding utf-8
" Vim filetype plugin file
" Language: PlantUML
-" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE
if exists('b:loaded_plantuml_plugin')
diff --git a/indent/basic.vim b/indent/basic.vim
new file mode 100644
index 00000000..7775bc4e
--- /dev/null
+++ b/indent/basic.vim
@@ -0,0 +1,15 @@
+if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'indent/basic.vim')
+ finish
+endif
+
+" Vim indent file
+" Language: BASIC (QuickBASIC 4.5)
+" Maintainer: Doug Kearns <dougkearns@gmail.com>
+" Last Change: 2022 Jan 24
+
+" Only load this indent file when no other was loaded.
+if exists("b:did_indent")
+ finish
+endif
+
+runtime! indent/vb.vim
diff --git a/indent/freebasic.vim b/indent/freebasic.vim
new file mode 100644
index 00000000..9399b57f
--- /dev/null
+++ b/indent/freebasic.vim
@@ -0,0 +1,15 @@
+if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'indent/freebasic.vim')
+ finish
+endif
+
+" Vim indent file
+" Language: FreeBASIC
+" Maintainer: Doug Kearns <dougkearns@gmail.com>
+" Last Change: 2022 Jan 24
+
+" Only load this indent file when no other was loaded.
+if exists("b:did_indent")
+ finish
+endif
+
+runtime! indent/vb.vim
diff --git a/indent/glsl.vim b/indent/glsl.vim
index b16fec47..60459284 100644
--- a/indent/glsl.vim
+++ b/indent/glsl.vim
@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'glsl', 'indent/glsl.vim')
endif
" Language: OpenGL Shading Language
-" Maintainer: Sergey Tikhomirov <sergey@tikhomirov.io>
+" Maintainer: Sergii Tykhomyrov <sergii@tykhomyrov.net>
if exists("b:did_indent")
finish
diff --git a/indent/markdown.vim b/indent/markdown.vim
index dd8888f4..3ad1d02e 100644
--- a/indent/markdown.vim
+++ b/indent/markdown.vim
@@ -2,7 +2,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'markdown', 'indent/markdown.v
finish
endif
-if exists("b:did_indent") | finish | endif
+if exists('b:did_indent') | finish | endif
let b:did_indent = 1
setlocal indentexpr=GetMarkdownIndent()
@@ -12,7 +12,7 @@ setlocal autoindent
" Automatically continue blockquote on line break
setlocal formatoptions+=r
setlocal comments=b:>
-if get(g:, "vim_markdown_auto_insert_bullets", 1)
+if get(g:, 'vim_markdown_auto_insert_bullets', 1)
" Do not automatically insert bullets when auto-wrapping with text-width
setlocal formatoptions-=c
" Accept various markers as bullets
@@ -20,24 +20,24 @@ if get(g:, "vim_markdown_auto_insert_bullets", 1)
endif
" Only define the function once
-if exists("*GetMarkdownIndent") | finish | endif
+if exists('*GetMarkdownIndent') | finish | endif
function! s:IsMkdCode(lnum)
let name = synIDattr(synID(a:lnum, 1, 0), 'name')
- return (name =~ '^mkd\%(Code$\|Snippet\)' || name != '' && name !~ '^\%(mkd\|html\)')
+ return (name =~# '^mkd\%(Code$\|Snippet\)' || name !=# '' && name !~? '^\%(mkd\|html\)')
endfunction
function! s:IsLiStart(line)
- return a:line !~ '^ *\([*-]\)\%( *\1\)\{2}\%( \|\1\)*$' &&
- \ a:line =~ '^\s*[*+-] \+'
+ return a:line !~# '^ *\([*-]\)\%( *\1\)\{2}\%( \|\1\)*$' &&
+ \ a:line =~# '^\s*[*+-] \+'
endfunction
function! s:IsHeaderLine(line)
- return a:line =~ '^\s*#'
+ return a:line =~# '^\s*#'
endfunction
function! s:IsBlankLine(line)
- return a:line =~ '^$'
+ return a:line =~# '^$'
endfunction
function! s:PrevNonBlank(lnum)
@@ -52,7 +52,7 @@ function GetMarkdownIndent()
if v:lnum > 2 && s:IsBlankLine(getline(v:lnum - 1)) && s:IsBlankLine(getline(v:lnum - 2))
return 0
endif
- let list_ind = get(g:, "vim_markdown_new_list_item_indent", 4)
+ let list_ind = get(g:, 'vim_markdown_new_list_item_indent', 4)
" Find a non-blank line above the current line.
let lnum = s:PrevNonBlank(v:lnum - 1)
" At the start of the file use zero indent.
diff --git a/indent/plantuml.vim b/indent/plantuml.vim
index 71af587c..1bf9d13e 100644
--- a/indent/plantuml.vim
+++ b/indent/plantuml.vim
@@ -5,7 +5,6 @@ endif
scriptencoding utf-8
" Vim indent file
" Language: PlantUML
-" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE
if exists('b:did_indent')
@@ -21,7 +20,7 @@ if exists('*GetPlantUMLIndent')
finish
endif
-let s:decIndent = '^\s*\%(end\|else\|}\)'
+let s:decIndent = '^\s*\%(end\|else\|fork again\|}\)'
function! GetPlantUMLIndent(...) abort
"for current line, use arg if given or v:lnum otherwise
diff --git a/indent/solidity.vim b/indent/solidity.vim
index 7744f7a7..26cb4c14 100644
--- a/indent/solidity.vim
+++ b/indent/solidity.vim
@@ -19,7 +19,7 @@ setlocal nosmartindent
" Now, set up our indentation expression and keys that trigger it.
setlocal indentexpr=GetSolidityIndent()
-setlocal indentkeys=0{,0},0),0],0\,,!^F,o,O,e
+setlocal indentkeys=0{,0},0),0],0\,,!^F,o,O,e,0*
" Only define the function once.
if exists("*GetSolidityIndent")
@@ -41,7 +41,7 @@ let s:syng_strcom = 'string\|regex\|comment\c'
let s:syng_string = 'regex\c'
" Regex of syntax group names that are strings or documentation.
-let s:syng_multiline = 'comment\c'
+let s:syng_multiline = 'comment\|natspecblock\c'
" Regex of syntax group names that are line comment.
let s:syng_linecom = 'linecomment\c'
diff --git a/syntax/basic.vim b/syntax/basic.vim
index 3502fa14..2984c9af 100644
--- a/syntax/basic.vim
+++ b/syntax/basic.vim
@@ -3,16 +3,17 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'syntax/basic.vim')
endif
" Vim syntax file
-" Language: BASIC
+" Language: BASIC (QuickBASIC 4.5)
" Maintainer: Doug Kearns <dougkearns@gmail.com>
" Previous Maintainer: Allan Kelly <allan@fruitloaf.co.uk>
" Contributors: Thilo Six
-" Last Change: 2015 Jan 10
+" Last Change: 2021 Aug 08
" First version based on Micro$soft QBASIC circa 1989, as documented in
" 'Learn BASIC Now' by Halvorson&Rygmyr. Microsoft Press 1989.
-" This syntax file not a complete implementation yet. Send suggestions to the
-" maintainer.
+"
+" Second version attempts to match Microsoft QuickBASIC 4.5 while keeping FreeBASIC
+" (-lang qb) and QB64 (excluding extensions) in mind. -- DJK
" Prelude {{{1
if exists("b:current_syntax")
@@ -22,154 +23,357 @@ endif
let s:cpo_save = &cpo
set cpo&vim
+syn iskeyword @,48-57,.,!,#,%,&,$
+syn case ignore
+
+" Whitespace Errors {{{1
+if exists("basic_space_errors")
+ if !exists("basic_no_trail_space_error")
+ syn match basicSpaceError display excludenl "\s\+$"
+ endif
+ if !exists("basic_no_tab_space_error")
+ syn match basicSpaceError display " \+\t"me=e-1
+ endif
+endif
+
+" Comment Errors {{{1
+if !exists("basic_no_comment_errors")
+ syn match basicCommentError "\<REM\>.*"
+endif
+
+" Not Top Cluster {{{1
+syn cluster basicNotTop contains=@basicLineIdentifier,basicDataString,basicDataSeparator,basicTodo
+
+" Statements {{{1
+
+syn cluster basicStatements contains=basicStatement,basicDataStatement,basicMetaRemStatement,basicPutStatement,basicRemStatement
+
+let s:statements =<< trim EOL " {{{2
+ beep
+ bload
+ bsave
+ call
+ calls
+ case
+ chain
+ chdir
+ circle
+ clear
+ close
+ cls
+ color
+ com
+ common
+ const
+ declare
+ def
+ def\s\+seg
+ defdbl
+ defint
+ deflng
+ defsng
+ defstr
+ dim
+ do
+ draw
+ elseif
+ end
+ end\s\+\%(def\|function\|if\|select\|sub\|type\)
+ environ
+ erase
+ error
+ exit\s\+\%(def\|do\|for\|function\|sub\)
+ field
+ files
+ for
+ function
+ get
+ gosub
+ goto
+ if
+ input
+ ioctl
+ key
+ kill
+ let
+ line
+ line\s\+input
+ locate
+ lock
+ loop
+ lprint
+ lset
+ mkdir
+ name
+ next
+ on
+ on\s\+error
+ on\s\+uevent
+ open
+ open\s\+com
+ option
+ out
+ paint
+ palette
+ palette\s\+using
+ pcopy
+ pen
+ pmap
+ poke
+ preset
+ print
+ pset
+ randomize
+ read
+ redim
+ reset
+ restore
+ resume
+ return
+ rmdir
+ rset
+ run
+ select\s\+case
+ shared
+ shell
+ sleep
+ sound
+ static
+ stop
+ strig
+ sub
+ swap
+ system
+ troff
+ tron
+ type
+ uevent
+ unlock
+ using
+ view
+ view\s\+print
+ wait
+ wend
+ while
+ width
+ window
+ write
+EOL
+" }}}
+
+for s in s:statements
+ exe 'syn match basicStatement "\<' .. s .. '\>" contained'
+endfor
+
+syn match basicStatement "\<\%(then\|else\)\>" nextgroup=@basicStatements skipwhite
+
+" DATA Statement
+syn match basicDataSeparator "," contained
+syn region basicDataStatement matchgroup=basicStatement start="\<data\>" matchgroup=basicStatementSeparator end=":\|$" contained contains=basicDataSeparator,basicDataString,basicNumber,basicFloat,basicString
+
+if !exists("basic_no_data_fold")
+ syn region basicMultilineData start="^\s*\<data\>.*\n\%(^\s*\<data\>\)\@=" end="^\s*\<data\>.*\n\%(^\s*\<data\>\)\@!" contains=basicDataStatement transparent fold keepend
+endif
+
+" PUT File I/O and Graphics statements - needs special handling for graphics
+" action verbs
+syn match basicPutAction "\<\%(pset\|preset\|and\|or\|xor\)\>" contained
+syn region basicPutStatement matchgroup=basicStatement start="\<put\>" matchgroup=basicStatementSeparator end=":\|$" contained contains=basicKeyword,basicPutAction,basicFilenumber
+
" Keywords {{{1
-syn keyword basicStatement BEEP beep Beep BLOAD bload Bload BSAVE bsave Bsave
-syn keyword basicStatement CALL call Call ABSOLUTE absolute Absolute
-syn keyword basicStatement CHAIN chain Chain CHDIR chdir Chdir
-syn keyword basicStatement CIRCLE circle Circle CLEAR clear Clear
-syn keyword basicStatement CLOSE close Close CLS cls Cls COLOR color Color
-syn keyword basicStatement COM com Com COMMON common Common
-syn keyword basicStatement CONST const Const DATA data Data
-syn keyword basicStatement DECLARE declare Declare DEF def Def
-syn keyword basicStatement DEFDBL defdbl Defdbl DEFINT defint Defint
-syn keyword basicStatement DEFLNG deflng Deflng DEFSNG defsng Defsng
-syn keyword basicStatement DEFSTR defstr Defstr DIM dim Dim
-syn keyword basicStatement DO do Do LOOP loop Loop
-syn keyword basicStatement DRAW draw Draw END end End
-syn keyword basicStatement ENVIRON environ Environ ERASE erase Erase
-syn keyword basicStatement ERROR error Error EXIT exit Exit
-syn keyword basicStatement FIELD field Field FILES files Files
-syn keyword basicStatement FOR for For NEXT next Next
-syn keyword basicStatement FUNCTION function Function GET get Get
-syn keyword basicStatement GOSUB gosub Gosub GOTO goto Goto
-syn keyword basicStatement IF if If THEN then Then ELSE else Else
-syn keyword basicStatement INPUT input Input INPUT# input# Input#
-syn keyword basicStatement IOCTL ioctl Ioctl KEY key Key
-syn keyword basicStatement KILL kill Kill LET let Let
-syn keyword basicStatement LINE line Line LOCATE locate Locate
-syn keyword basicStatement LOCK lock Lock UNLOCK unlock Unlock
-syn keyword basicStatement LPRINT lprint Lprint USING using Using
-syn keyword basicStatement LSET lset Lset MKDIR mkdir Mkdir
-syn keyword basicStatement NAME name Name ON on On
-syn keyword basicStatement ERROR error Error OPEN open Open
-syn keyword basicStatement OPTION option Option BASE base Base
-syn keyword basicStatement OUT out Out PAINT paint Paint
-syn keyword basicStatement PALETTE palette Palette PCOPY pcopy Pcopy
-syn keyword basicStatement PEN pen Pen PLAY play Play
-syn keyword basicStatement PMAP pmap Pmap POKE poke Poke
-syn keyword basicStatement PRESET preset Preset PRINT print Print
-syn keyword basicStatement PRINT# print# Print# USING using Using
-syn keyword basicStatement PSET pset Pset PUT put Put
-syn keyword basicStatement RANDOMIZE randomize Randomize READ read Read
-syn keyword basicStatement REDIM redim Redim RESET reset Reset
-syn keyword basicStatement RESTORE restore Restore RESUME resume Resume
-syn keyword basicStatement RETURN return Return RMDIR rmdir Rmdir
-syn keyword basicStatement RSET rset Rset RUN run Run
-syn keyword basicStatement SEEK seek Seek SELECT select Select
-syn keyword basicStatement CASE case Case SHARED shared Shared
-syn keyword basicStatement SHELL shell Shell SLEEP sleep Sleep
-syn keyword basicStatement SOUND sound Sound STATIC static Static
-syn keyword basicStatement STOP stop Stop STRIG strig Strig
-syn keyword basicStatement SUB sub Sub SWAP swap Swap
-syn keyword basicStatement SYSTEM system System TIMER timer Timer
-syn keyword basicStatement TROFF troff Troff TRON tron Tron
-syn keyword basicStatement TYPE type Type UNLOCK unlock Unlock
-syn keyword basicStatement VIEW view View WAIT wait Wait
-syn keyword basicStatement WHILE while While WEND wend Wend
-syn keyword basicStatement WIDTH width Width WINDOW window Window
-syn keyword basicStatement WRITE write Write DATE$ date$ Date$
-syn keyword basicStatement MID$ mid$ Mid$ TIME$ time$ Time$
-
-syn keyword basicFunction ABS abs Abs ASC asc Asc
-syn keyword basicFunction ATN atn Atn CDBL cdbl Cdbl
-syn keyword basicFunction CINT cint Cint CLNG clng Clng
-syn keyword basicFunction COS cos Cos CSNG csng Csng
-syn keyword basicFunction CSRLIN csrlin Csrlin CVD cvd Cvd
-syn keyword basicFunction CVDMBF cvdmbf Cvdmbf CVI cvi Cvi
-syn keyword basicFunction CVL cvl Cvl CVS cvs Cvs
-syn keyword basicFunction CVSMBF cvsmbf Cvsmbf EOF eof Eof
-syn keyword basicFunction ERDEV erdev Erdev ERL erl Erl
-syn keyword basicFunction ERR err Err EXP exp Exp
-syn keyword basicFunction FILEATTR fileattr Fileattr FIX fix Fix
-syn keyword basicFunction FRE fre Fre FREEFILE freefile Freefile
-syn keyword basicFunction INP inp Inp INSTR instr Instr
-syn keyword basicFunction INT int Int LBOUND lbound Lbound
-syn keyword basicFunction LEN len Len LOC loc Loc
-syn keyword basicFunction LOF lof Lof LOG log Log
-syn keyword basicFunction LPOS lpos Lpos PEEK peek Peek
-syn keyword basicFunction PEN pen Pen POINT point Point
-syn keyword basicFunction POS pos Pos RND rnd Rnd
-syn keyword basicFunction SADD sadd Sadd SCREEN screen Screen
-syn keyword basicFunction SEEK seek Seek SETMEM setmem Setmem
-syn keyword basicFunction SGN sgn Sgn SIN sin Sin
-syn keyword basicFunction SPC spc Spc SQR sqr Sqr
-syn keyword basicFunction STICK stick Stick STRIG strig Strig
-syn keyword basicFunction TAB tab Tab TAN tan Tan
-syn keyword basicFunction UBOUND ubound Ubound VAL val Val
-syn keyword basicFunction VALPTR valptr Valptr VALSEG valseg Valseg
-syn keyword basicFunction VARPTR varptr Varptr VARSEG varseg Varseg
-syn keyword basicFunction CHR$ Chr$ chr$ COMMAND$ command$ Command$
-syn keyword basicFunction DATE$ date$ Date$ ENVIRON$ environ$ Environ$
-syn keyword basicFunction ERDEV$ erdev$ Erdev$ HEX$ hex$ Hex$
-syn keyword basicFunction INKEY$ inkey$ Inkey$ INPUT$ input$ Input$
-syn keyword basicFunction IOCTL$ ioctl$ Ioctl$ LCASES$ lcases$ Lcases$
-syn keyword basicFunction LAFT$ laft$ Laft$ LTRIM$ ltrim$ Ltrim$
-syn keyword basicFunction MID$ mid$ Mid$ MKDMBF$ mkdmbf$ Mkdmbf$
-syn keyword basicFunction MKD$ mkd$ Mkd$ MKI$ mki$ Mki$
-syn keyword basicFunction MKL$ mkl$ Mkl$ MKSMBF$ mksmbf$ Mksmbf$
-syn keyword basicFunction MKS$ mks$ Mks$ OCT$ oct$ Oct$
-syn keyword basicFunction RIGHT$ right$ Right$ RTRIM$ rtrim$ Rtrim$
-syn keyword basicFunction SPACE$ space$ Space$ STR$ str$ Str$
-syn keyword basicFunction STRING$ string$ String$ TIME$ time$ Time$
-syn keyword basicFunction UCASE$ ucase$ Ucase$ VARPTR$ varptr$ Varptr$
+let s:keywords =<< trim EOL " {{{2
+ absolute
+ access
+ alias
+ append
+ as
+ base
+ binary
+ byval
+ cdecl
+ com
+ def
+ do
+ for
+ function
+ gosub
+ goto
+ input
+ int86old
+ int86xold
+ interrupt
+ interruptx
+ is
+ key
+ len
+ list
+ local
+ lock
+ lprint
+ next
+ off
+ on
+ output
+ pen
+ play
+ random
+ read
+ resume
+ screen
+ seg
+ shared
+ signal
+ static
+ step
+ stop
+ strig
+ sub
+ timer
+ to
+ until
+ using
+ while
+ write
+EOL
+" }}}
+
+for k in s:keywords
+ exe 'syn match basicKeyword "\<' .. k .. '\>"'
+endfor
+
+" Functions {{{1
+syn keyword basicFunction abs asc atn cdbl chr$ cint clng command$ cos csng
+syn keyword basicFunction csrlin cvd cvdmbf cvi cvl cvs cvsmbf environ$ eof
+syn keyword basicFunction erdev erdev$ erl err exp fileattr fix fre freefile
+syn keyword basicFunction hex$ inkey$ inp input$ instr int ioctl$ left$ lbound
+syn keyword basicFunction lcase$ len loc lof log lpos ltrim$ mkd$ mkdmbf$ mki$
+syn keyword basicFunction mkl$ mks$ mksmbf$ oct$ peek pen point pos right$ rnd
+syn keyword basicFunction rtrim$ sadd setmem sgn sin space$ spc sqr stick str$
+syn keyword basicFunction strig string$ tab tan ubound ucase$ val valptr
+syn keyword basicFunction valseg varptr varptr$ varseg
+
+" Functions and statements (same name) {{{1
+syn match basicStatement "\<\%(date\$\|mid\$\|play\|screen\|seek\|time\$\|timer\)\>" contained
+syn match basicFunction "\<\%(date\$\|mid\$\|play\|screen\|seek\|time\$\|timer\)\>"
+
+" Types {{{1
+syn keyword basicType integer long single double string any
+
+" Strings {{{1
+
+" Unquoted DATA strings - anything except [:,] and leading or trailing whitespace
+" Needs lower priority than numbers
+syn match basicDataString "[^[:space:],:]\+\%(\s\+[^[:space:],:]\+\)*" contained
+
+syn region basicString start=+"+ end=+"+ oneline
+
+" Booleans {{{1
+if exists("basic_booleans")
+ syn keyword basicBoolean true false
+endif
" Numbers {{{1
-" Integer number, or floating point number without a dot.
-syn match basicNumber "\<\d\+\>"
-" Floating point number, with dot
-syn match basicNumber "\<\d\+\.\d*\>"
-" Floating point number, starting with a dot
-syn match basicNumber "\.\d\+\>"
-" String and Character constants {{{1
-syn match basicSpecial "\\\d\d\d\|\\." contained
-syn region basicString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=basicSpecial
+" Integers
+syn match basicNumber "-\=&o\=\o\+[%&]\=\>"
+syn match basicNumber "-\=&h\x\+[%&]\=\>"
+syn match basicNumber "-\=\<\d\+[%&]\=\>"
+
+" Floats
+syn match basicFloat "-\=\<\d\+\.\=\d*\%(\%([ed][+-]\=\d*\)\|[!#]\)\=\>"
+syn match basicFloat "-\=\<\.\d\+\%(\%([ed][+-]\=\d*\)\|[!#]\)\=\>"
-" Line numbers {{{1
-syn region basicLineNumber start="^\d" end="\s"
+" Statement anchors {{{1
+syn match basicLineStart "^" nextgroup=@basicStatements,@basicLineIdentifier skipwhite
+syn match basicStatementSeparator ":" nextgroup=@basicStatements skipwhite
-" Data-type suffixes {{{1
-syn match basicTypeSpecifier "[a-zA-Z0-9][$%&!#]"ms=s+1
-" Used with OPEN statement
-syn match basicFilenumber "#\d\+"
+" Line numbers and labels {{{1
+
+" QuickBASIC limits these to 65,529 and 40 chars respectively
+syn match basicLineNumber "\d\+" nextgroup=@basicStatements skipwhite contained
+syn match basicLineLabel "\a[[:alnum:]]*\ze\s*:" nextgroup=@basicStatements skipwhite contained
+
+syn cluster basicLineIdentifier contains=basicLineNumber,basicLineLabel
+
+" Line Continuation {{{1
+syn match basicLineContinuation "\s*\zs_\ze\s*$"
+
+" Type suffixes {{{1
+if exists("basic_type_suffixes")
+ syn match basicTypeSuffix "\a[[:alnum:].]*\zs[$%&!#]"
+endif
-" Mathematical operators {{{1
-" syn match basicMathsOperator "[<>+\*^/\\=-]"
-syn match basicMathsOperator "-\|=\|[:<>+\*^/\\]\|AND\|OR"
+" File numbers {{{1
+syn match basicFilenumber "#\d\+"
+syn match basicFilenumber "#\a[[:alnum:].]*[%&!#]\="
+
+" Operators {{{1
+if exists("basic_operators")
+ syn match basicArithmeticOperator "[-+*/\\^]"
+ syn match basicRelationalOperator "<>\|<=\|>=\|[><=]"
+endif
+syn match basicLogicalOperator "\<\%(not\|and\|or\|xor\|eqv\|imp\)\>"
+syn match basicArithmeticOperator "\<mod\>"
+
+" Metacommands {{{1
+" Note: No trailing word boundaries. Text may be freely mixed however there
+" must be only leading whitespace prior to the first metacommand
+syn match basicMetacommand "$INCLUDE\s*:\s*'[^']\+'" contained containedin=@basicMetaComments
+syn match basicMetacommand "$\%(DYNAMIC\|STATIC\)" contained containedin=@basicMetaComments
" Comments {{{1
-syn keyword basicTodo TODO FIXME XXX NOTE contained
-syn region basicComment start="^\s*\zsREM\>" start="\%(:\s*\)\@<=REM\>" end="$" contains=basicTodo
-syn region basicComment start="'" end="$" contains=basicTodo
+syn keyword basicTodo TODO FIXME XXX NOTE contained
+
+syn region basicRemStatement matchgroup=basicStatement start="REM\>" end="$" contains=basicTodo,@Spell contained
+syn region basicComment start="'" end="$" contains=basicTodo,@Spell
+
+if !exists("basic_no_comment_fold")
+ syn region basicMultilineComment start="^\s*'.*\n\%(\s*'\)\@=" end="^\s*'.*\n\%(\s*'\)\@!" contains=@basicComments transparent fold keepend
+endif
+
+" Metacommands
+syn region basicMetaRemStatement matchgroup=basicStatement start="REM\>\s*\$\@=" end="$" contains=basicTodo contained
+syn region basicMetaComment start="'\s*\$\@=" end="$" contains=basicTodo
+
+syn cluster basicMetaComments contains=basicMetaComment,basicMetaRemStatement
+syn cluster basicComments contains=basicComment,basicMetaComment
"syn sync ccomment basicComment
" Default Highlighting {{{1
-hi def link basicLabel Label
-hi def link basicConditional Conditional
-hi def link basicRepeat Repeat
-hi def link basicLineNumber Comment
-hi def link basicNumber Number
-hi def link basicError Error
-hi def link basicStatement Statement
-hi def link basicString String
-hi def link basicComment Comment
-hi def link basicSpecial Special
-hi def link basicTodo Todo
-hi def link basicFunction Identifier
-hi def link basicTypeSpecifier Type
-hi def link basicFilenumber basicTypeSpecifier
-"hi basicMathsOperator term=bold cterm=bold gui=bold
+hi def link basicArithmeticOperator basicOperator
+hi def link basicBoolean Boolean
+hi def link basicComment Comment
+hi def link basicCommentError Error
+hi def link basicDataString basicString
+hi def link basicFilenumber basicTypeSuffix " TODO: better group
+hi def link basicFloat Float
+hi def link basicFunction Identifier
+hi def link basicKeyword Keyword
+hi def link basicLineIdentifier LineNr
+hi def link basicLineContinuation Special
+hi def link basicLineLabel basicLineIdentifier
+hi def link basicLineNumber basicLineIdentifier
+hi def link basicLogicalOperator basicOperator
+hi def link basicMetacommand SpecialComment
+hi def link basicMetaComment Comment
+hi def link basicMetaRemStatement Comment
+hi def link basicNumber Number
+hi def link basicOperator Operator
+hi def link basicPutAction Keyword
+hi def link basicRelationalOperator basicOperator
+hi def link basicRemStatement Comment
+hi def link basicSpaceError Error
+hi def link basicStatementSeparator Special
+hi def link basicStatement Statement
+hi def link basicString String
+hi def link basicTodo Todo
+hi def link basicType Type
+hi def link basicTypeSuffix Special
+if exists("basic_legacy_syntax_groups")
+ hi def link basicTypeSpecifier Type
+ hi def link basicTypeSuffix basicTypeSpecifier
+endif
" Postscript {{{1
let b:current_syntax = "basic"
diff --git a/syntax/clojure.vim b/syntax/clojure.vim
index 6fb36244..2be3626f 100644
--- a/syntax/clojure.vim
+++ b/syntax/clojure.vim
@@ -28,17 +28,17 @@ endif
" Generated from https://github.com/clojure-vim/clojure.vim/blob/%%RELEASE_TAG%%/clj/src/vim_clojure_static/generate.clj
" Clojure version 1.10.3
let s:clojure_syntax_keywords = {
- \ 'clojureBoolean': ["false","true"]
- \ , 'clojureCond': ["case","clojure.core/case","clojure.core/cond","clojure.core/cond->","clojure.core/cond->>","clojure.core/condp","clojure.core/if-let","clojure.core/if-not","clojure.core/if-some","clojure.core/when","clojure.core/when-first","clojure.core/when-let","clojure.core/when-not","clojure.core/when-some","cond","cond->","cond->>","condp","if-let","if-not","if-some","when","when-first","when-let","when-not","when-some"]
- \ , 'clojureConstant': ["nil"]
- \ , 'clojureDefine': ["clojure.core/definline","clojure.core/definterface","clojure.core/defmacro","clojure.core/defmethod","clojure.core/defmulti","clojure.core/defn","clojure.core/defn-","clojure.core/defonce","clojure.core/defprotocol","clojure.core/defrecord","clojure.core/defstruct","clojure.core/deftype","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype"]
- \ , 'clojureException': ["catch","finally","throw","try"]
- \ , 'clojureFunc': ["*","*'","+","+'","-","-'","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods","/","<","<=","=","==",">",">=","PrintWriter-on","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-tap","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","ancestors","any?","apply","array-map","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assoc","assoc!","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","cast","cat","char","char-array","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","clojure.core/*","clojure.core/*'","clojure.core/+","clojure.core/+'","clojure.core/-","clojure.core/-'","clojure.core/->ArrayChunk","clojure.core/->Eduction","clojure.core/->Vec","clojure.core/->VecNode","clojure.core/->VecSeq","clojure.core/-cache-protocol-fn","clojure.core/-reset-methods","clojure.core//","clojure.core/<","clojure.core/<=","clojure.core/=","clojure.core/==","clojure.core/>","clojure.core/>=","clojure.core/PrintWriter-on","clojure.core/StackTraceElement->vec","clojure.core/Throwable->map","clojure.core/accessor","clojure.core/aclone","clojure.core/add-classpath","clojure.core/add-tap","clojure.core/add-watch","clojure.core/agent","clojure.core/agent-error","clojure.core/agent-errors","clojure.core/aget","clojure.core/alength","clojure.core/alias","clojure.core/all-ns","clojure.core/alter","clojure.core/alter-meta!","clojure.core/alter-var-root","clojure.core/ancestors","clojure.core/any?","clojure.core/apply","clojure.core/array-map","clojure.core/aset","clojure.core/aset-boolean","clojure.core/aset-byte","clojure.core/aset-char","clojure.core/aset-double","clojure.core/aset-float","clojure.core/aset-int","clojure.core/aset-long","clojure.core/aset-short","clojure.core/assoc","clojure.core/assoc!","clojure.core/assoc-in","clojure.core/associative?","clojure.core/atom","clojure.core/await","clojure.core/await-for","clojure.core/await1","clojure.core/bases","clojure.core/bean","clojure.core/bigdec","clojure.core/bigint","clojure.core/biginteger","clojure.core/bit-and","clojure.core/bit-and-not","clojure.core/bit-clear","clojure.core/bit-flip","clojure.core/bit-not","clojure.core/bit-or","clojure.core/bit-set","clojure.core/bit-shift-left","clojure.core/bit-shift-right","clojure.core/bit-test","clojure.core/bit-xor","clojure.core/boolean","clojure.core/boolean-array","clojure.core/boolean?","clojure.core/booleans","clojure.core/bound-fn*","clojure.core/bound?","clojure.core/bounded-count","clojure.core/butlast","clojure.core/byte","clojure.core/byte-array","clojure.core/bytes","clojure.core/bytes?","clojure.core/cast","clojure.core/cat","clojure.core/char","clojure.core/char-array","clojure.core/char?","clojure.core/chars","clojure.core/chunk","clojure.core/chunk-append","clojure.core/chunk-buffer","clojure.core/chunk-cons","clojure.core/chunk-first","clojure.core/chunk-next","clojure.core/chunk-rest","clojure.core/chunked-seq?","clojure.core/class","clojure.core/class?","clojure.core/clear-agent-errors","clojure.core/clojure-version","clojure.core/coll?","clojure.core/commute","clojure.core/comp","clojure.core/comparator","clojure.core/compare","clojure.core/compare-and-set!","clojure.core/compile","clojure.core/complement","clojure.core/completing","clojure.core/concat","clojure.core/conj","clojure.core/conj!","clojure.core/cons","clojure.core/constantly","clojure.core/construct-proxy","clojure.core/contains?","clojure.core/count","clojure.core/counted?","clojure.core/create-ns","clojure.core/create-struct","clojure.core/cycle","clojure.core/dec","clojure.core/dec'","clojure.core/decimal?","clojure.core/dedupe","clojure.core/delay?","clojure.core/deliver","clojure.core/denominator","clojure.core/deref","clojure.core/derive","clojure.core/descendants","clojure.core/destructure","clojure.core/disj","clojure.core/disj!","clojure.core/dissoc","clojure.core/dissoc!","clojure.core/distinct","clojure.core/distinct?","clojure.core/doall","clojure.core/dorun","clojure.core/double","clojure.core/double-array","clojure.core/double?","clojure.core/doubles","clojure.core/drop","clojure.core/drop-last","clojure.core/drop-while","clojure.core/eduction","clojure.core/empty","clojure.core/empty?","clojure.core/ensure","clojure.core/ensure-reduced","clojure.core/enumeration-seq","clojure.core/error-handler","clojure.core/error-mode","clojure.core/eval","clojure.core/even?","clojure.core/every-pred","clojure.core/every?","clojure.core/ex-cause","clojure.core/ex-data","clojure.core/ex-info","clojure.core/ex-message","clojure.core/extend","clojure.core/extenders","clojure.core/extends?","clojure.core/false?","clojure.core/ffirst","clojure.core/file-seq","clojure.core/filter","clojure.core/filterv","clojure.core/find","clojure.core/find-keyword","clojure.core/find-ns","clojure.core/find-protocol-impl","clojure.core/find-protocol-method","clojure.core/find-var","clojure.core/first","clojure.core/flatten","clojure.core/float","clojure.core/float-array","clojure.core/float?","clojure.core/floats","clojure.core/flush","clojure.core/fn?","clojure.core/fnext","clojure.core/fnil","clojure.core/force","clojure.core/format","clojure.core/frequencies","clojure.core/future-call","clojure.core/future-cancel","clojure.core/future-cancelled?","clojure.core/future-done?","clojure.core/future?","clojure.core/gensym","clojure.core/get","clojure.core/get-in","clojure.core/get-method","clojure.core/get-proxy-class","clojure.core/get-thread-bindings","clojure.core/get-validator","clojure.core/group-by","clojure.core/halt-when","clojure.core/hash","clojure.core/hash-combine","clojure.core/hash-map","clojure.core/hash-ordered-coll","clojure.core/hash-set","clojure.core/hash-unordered-coll","clojure.core/ident?","clojure.core/identical?","clojure.core/identity","clojure.core/ifn?","clojure.core/in-ns","clojure.core/inc","clojure.core/inc'","clojure.core/indexed?","clojure.core/init-proxy","clojure.core/inst-ms","clojure.core/inst-ms*","clojure.core/inst?","clojure.core/instance?","clojure.core/int","clojure.core/int-array","clojure.core/int?","clojure.core/integer?","clojure.core/interleave","clojure.core/intern","clojure.core/interpose","clojure.core/into","clojure.core/into-array","clojure.core/ints","clojure.core/isa?","clojure.core/iterate","clojure.core/iterator-seq","clojure.core/juxt","clojure.core/keep","clojure.core/keep-indexed","clojure.core/key","clojure.core/keys","clojure.core/keyword","clojure.core/keyword?","clojure.core/last","clojure.core/line-seq","clojure.core/list","clojure.core/list*","clojure.core/list?","clojure.core/load","clojure.core/load-file","clojure.core/load-reader","clojure.core/load-string","clojure.core/loaded-libs","clojure.core/long","clojure.core/long-array","clojure.core/longs","clojure.core/macroexpand","clojure.core/macroexpand-1","clojure.core/make-array","clojure.core/make-hierarchy","clojure.core/map","clojure.core/map-entry?","clojure.core/map-indexed","clojure.core/map?","clojure.core/mapcat","clojure.core/mapv","clojure.core/max","clojure.core/max-key","clojure.core/memoize","clojure.core/merge","clojure.core/merge-with","clojure.core/meta","clojure.core/method-sig","clojure.core/methods","clojure.core/min","clojure.core/min-key","clojure.core/mix-collection-hash","clojure.core/mod","clojure.core/munge","clojure.core/name","clojure.core/namespace","clojure.core/namespace-munge","clojure.core/nat-int?","clojure.core/neg-int?","clojure.core/neg?","clojure.core/newline","clojure.core/next","clojure.core/nfirst","clojure.core/nil?","clojure.core/nnext","clojure.core/not","clojure.core/not-any?","clojure.core/not-empty","clojure.core/not-every?","clojure.core/not=","clojure.core/ns-aliases","clojure.core/ns-imports","clojure.core/ns-interns","clojure.core/ns-map","clojure.core/ns-name","clojure.core/ns-publics","clojure.core/ns-refers","clojure.core/ns-resolve","clojure.core/ns-unalias","clojure.core/ns-unmap","clojure.core/nth","clojure.core/nthnext","clojure.core/nthrest","clojure.core/num","clojure.core/number?","clojure.core/numerator","clojure.core/object-array","clojure.core/odd?","clojure.core/parents","clojure.core/partial","clojure.core/partition","clojure.core/partition-all","clojure.core/partition-by","clojure.core/pcalls","clojure.core/peek","clojure.core/persistent!","clojure.core/pmap","clojure.core/pop","clojure.core/pop!","clojure.core/pop-thread-bindings","clojure.core/pos-int?","clojure.core/pos?","clojure.core/pr","clojure.core/pr-str","clojure.core/prefer-method","clojure.core/prefers","clojure.core/print","clojure.core/print-ctor","clojure.core/print-dup","clojure.core/print-method","clojure.core/print-simple","clojure.core/print-str","clojure.core/printf","clojure.core/println","clojure.core/println-str","clojure.core/prn","clojure.core/prn-str","clojure.core/promise","clojure.core/proxy-call-with-super","clojure.core/proxy-mappings","clojure.core/proxy-name","clojure.core/push-thread-bindings","clojure.core/qualified-ident?","clojure.core/qualified-keyword?","clojure.core/qualified-symbol?","clojure.core/quot","clojure.core/rand","clojure.core/rand-int","clojure.core/rand-nth","clojure.core/random-sample","clojure.core/range","clojure.core/ratio?","clojure.core/rational?","clojure.core/rationalize","clojure.core/re-find","clojure.core/re-groups","clojure.core/re-matcher","clojure.core/re-matches","clojure.core/re-pattern","clojure.core/re-seq","clojure.core/read","clojure.core/read+string","clojure.core/read-line","clojure.core/read-string","clojure.core/reader-conditional","clojure.core/reader-conditional?","clojure.core/realized?","clojure.core/record?","clojure.core/reduce","clojure.core/reduce-kv","clojure.core/reduced","clojure.core/reduced?","clojure.core/reductions","clojure.core/ref","clojure.core/ref-history-count","clojure.core/ref-max-history","clojure.core/ref-min-history","clojure.core/ref-set","clojure.core/refer","clojure.core/release-pending-sends","clojure.core/rem","clojure.core/remove","clojure.core/remove-all-methods","clojure.core/remove-method","clojure.core/remove-ns","clojure.core/remove-tap","clojure.core/remove-watch","clojure.core/repeat","clojure.core/repeatedly","clojure.core/replace","clojure.core/replicate","clojure.core/require","clojure.core/requiring-resolve","clojure.core/reset!","clojure.core/reset-meta!","clojure.core/reset-vals!","clojure.core/resolve","clojure.core/rest","clojure.core/restart-agent","clojure.core/resultset-seq","clojure.core/reverse","clojure.core/reversible?","clojure.core/rseq","clojure.core/rsubseq","clojure.core/run!","clojure.core/satisfies?","clojure.core/second","clojure.core/select-keys","clojure.core/send","clojure.core/send-off","clojure.core/send-via","clojure.core/seq","clojure.core/seq?","clojure.core/seqable?","clojure.core/seque","clojure.core/sequence","clojure.core/sequential?","clojure.core/set","clojure.core/set-agent-send-executor!","clojure.core/set-agent-send-off-executor!","clojure.core/set-error-handler!","clojure.core/set-error-mode!","clojure.core/set-validator!","clojure.core/set?","clojure.core/short","clojure.core/short-array","clojure.core/shorts","clojure.core/shuffle","clojure.core/shutdown-agents","clojure.core/simple-ident?","clojure.core/simple-keyword?","clojure.core/simple-symbol?","clojure.core/slurp","clojure.core/some","clojure.core/some-fn","clojure.core/some?","clojure.core/sort","clojure.core/sort-by","clojure.core/sorted-map","clojure.core/sorted-map-by","clojure.core/sorted-set","clojure.core/sorted-set-by","clojure.core/sorted?","clojure.core/special-symbol?","clojure.core/spit","clojure.core/split-at","clojure.core/split-with","clojure.core/str","clojure.core/string?","clojure.core/struct","clojure.core/struct-map","clojure.core/subs","clojure.core/subseq","clojure.core/subvec","clojure.core/supers","clojure.core/swap!","clojure.core/swap-vals!","clojure.core/symbol","clojure.core/symbol?","clojure.core/tagged-literal","clojure.core/tagged-literal?","clojure.core/take","clojure.core/take-last","clojure.core/take-nth","clojure.core/take-while","clojure.core/tap>","clojure.core/test","clojure.core/the-ns","clojure.core/thread-bound?","clojure.core/to-array","clojure.core/to-array-2d","clojure.core/trampoline","clojure.core/transduce","clojure.core/transient","clojure.core/tree-seq","clojure.core/true?","clojure.core/type","clojure.core/unchecked-add","clojure.core/unchecked-add-int","clojure.core/unchecked-byte","clojure.core/unchecked-char","clojure.core/unchecked-dec","clojure.core/unchecked-dec-int","clojure.core/unchecked-divide-int","clojure.core/unchecked-double","clojure.core/unchecked-float","clojure.core/unchecked-inc","clojure.core/unchecked-inc-int","clojure.core/unchecked-int","clojure.core/unchecked-long","clojure.core/unchecked-multiply","clojure.core/unchecked-multiply-int","clojure.core/unchecked-negate","clojure.core/unchecked-negate-int","clojure.core/unchecked-remainder-int","clojure.core/unchecked-short","clojure.core/unchecked-subtract","clojure.core/unchecked-subtract-int","clojure.core/underive","clojure.core/unreduced","clojure.core/unsigned-bit-shift-right","clojure.core/update","clojure.core/update-in","clojure.core/update-proxy","clojure.core/uri?","clojure.core/use","clojure.core/uuid?","clojure.core/val","clojure.core/vals","clojure.core/var-get","clojure.core/var-set","clojure.core/var?","clojure.core/vary-meta","clojure.core/vec","clojure.core/vector","clojure.core/vector-of","clojure.core/vector?","clojure.core/volatile!","clojure.core/volatile?","clojure.core/vreset!","clojure.core/with-bindings*","clojure.core/with-meta","clojure.core/with-redefs-fn","clojure.core/xml-seq","clojure.core/zero?","clojure.core/zipmap","coll?","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","conj","conj!","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","dedupe","delay?","deliver","denominator","deref","derive","descendants","destructure","disj","disj!","dissoc","dissoc!","distinct","distinct?","doall","dorun","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-cause","ex-data","ex-info","ex-message","extend","extenders","extends?","false?","ffirst","file-seq","filter","filterv","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn?","fnext","fnil","force","format","frequencies","future-call","future-cancel","future-cancelled?","future-done?","future?","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","ifn?","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","long","long-array","longs","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop","pop!","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy-call-with-super","proxy-mappings","proxy-name","push-thread-bindings","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read+string","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-tap","remove-watch","repeat","repeatedly","replace","replicate","require","requiring-resolve","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","tap>","test","the-ns","thread-bound?","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","with-bindings*","with-meta","with-redefs-fn","xml-seq","zero?","zipmap"]
- \ , 'clojureMacro': ["->","->>","..","amap","and","areduce","as->","assert","binding","bound-fn","clojure.core/->","clojure.core/->>","clojure.core/..","clojure.core/amap","clojure.core/and","clojure.core/areduce","clojure.core/as->","clojure.core/assert","clojure.core/binding","clojure.core/bound-fn","clojure.core/comment","clojure.core/declare","clojure.core/delay","clojure.core/dosync","clojure.core/doto","clojure.core/extend-protocol","clojure.core/extend-type","clojure.core/for","clojure.core/future","clojure.core/gen-class","clojure.core/gen-interface","clojure.core/import","clojure.core/io!","clojure.core/lazy-cat","clojure.core/lazy-seq","clojure.core/letfn","clojure.core/locking","clojure.core/memfn","clojure.core/ns","clojure.core/or","clojure.core/proxy","clojure.core/proxy-super","clojure.core/pvalues","clojure.core/refer-clojure","clojure.core/reify","clojure.core/some->","clojure.core/some->>","clojure.core/sync","clojure.core/time","clojure.core/vswap!","clojure.core/with-bindings","clojure.core/with-in-str","clojure.core/with-loading-context","clojure.core/with-local-vars","clojure.core/with-open","clojure.core/with-out-str","clojure.core/with-precision","clojure.core/with-redefs","comment","declare","delay","dosync","doto","extend-protocol","extend-type","for","future","gen-class","gen-interface","import","io!","lazy-cat","lazy-seq","letfn","locking","memfn","ns","or","proxy","proxy-super","pvalues","refer-clojure","reify","some->","some->>","sync","time","vswap!","with-bindings","with-in-str","with-loading-context","with-local-vars","with-open","with-out-str","with-precision","with-redefs"]
- \ , 'clojureRepeat': ["clojure.core/doseq","clojure.core/dotimes","clojure.core/while","doseq","dotimes","while"]
- \ , 'clojureSpecial': [".","clojure.core/fn","clojure.core/let","clojure.core/loop","def","do","fn","if","let","loop","monitor-enter","monitor-exit","new","quote","recur","set!","var"]
- \ , 'clojureVariable': ["*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","EMPTY-NODE","Inst","char-escape-string","char-name-string","clojure.core/*1","clojure.core/*2","clojure.core/*3","clojure.core/*agent*","clojure.core/*allow-unresolved-vars*","clojure.core/*assert*","clojure.core/*clojure-version*","clojure.core/*command-line-args*","clojure.core/*compile-files*","clojure.core/*compile-path*","clojure.core/*compiler-options*","clojure.core/*data-readers*","clojure.core/*default-data-reader-fn*","clojure.core/*e","clojure.core/*err*","clojure.core/*file*","clojure.core/*flush-on-newline*","clojure.core/*fn-loader*","clojure.core/*in*","clojure.core/*math-context*","clojure.core/*ns*","clojure.core/*out*","clojure.core/*print-dup*","clojure.core/*print-length*","clojure.core/*print-level*","clojure.core/*print-meta*","clojure.core/*print-namespace-maps*","clojure.core/*print-readably*","clojure.core/*read-eval*","clojure.core/*reader-resolver*","clojure.core/*source-path*","clojure.core/*suppress-read*","clojure.core/*unchecked-math*","clojure.core/*use-context-classloader*","clojure.core/*verbose-defrecords*","clojure.core/*warn-on-reflection*","clojure.core/EMPTY-NODE","clojure.core/Inst","clojure.core/char-escape-string","clojure.core/char-name-string","clojure.core/default-data-readers","clojure.core/primitives-classnames","clojure.core/unquote","clojure.core/unquote-splicing","default-data-readers","primitives-classnames","unquote","unquote-splicing"]
- \ }
+ \ 'clojureBoolean': ["false","true"],
+ \ 'clojureCond': ["case","case*","clojure.core/case","clojure.core/cond","clojure.core/cond->","clojure.core/cond->>","clojure.core/condp","clojure.core/if-let","clojure.core/if-not","clojure.core/if-some","clojure.core/when","clojure.core/when-first","clojure.core/when-let","clojure.core/when-not","clojure.core/when-some","cond","cond->","cond->>","condp","if","if-let","if-not","if-some","when","when-first","when-let","when-not","when-some"],
+ \ 'clojureConstant': ["nil"],
+ \ 'clojureDefine': ["clojure.core/definline","clojure.core/definterface","clojure.core/defmacro","clojure.core/defmethod","clojure.core/defmulti","clojure.core/defn","clojure.core/defn-","clojure.core/defonce","clojure.core/defprotocol","clojure.core/defrecord","clojure.core/defstruct","clojure.core/deftype","def","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","deftype*"],
+ \ 'clojureException': ["catch","finally","throw","try"],
+ \ 'clojureFunc': ["*","*'","+","+'","-","-'","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods","/","<","<=","=","==",">",">=","PrintWriter-on","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-tap","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","ancestors","any?","apply","array-map","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assoc","assoc!","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","cast","cat","char","char-array","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","clojure.core/*","clojure.core/*'","clojure.core/+","clojure.core/+'","clojure.core/-","clojure.core/-'","clojure.core/->ArrayChunk","clojure.core/->Eduction","clojure.core/->Vec","clojure.core/->VecNode","clojure.core/->VecSeq","clojure.core/-cache-protocol-fn","clojure.core/-reset-methods","clojure.core//","clojure.core/<","clojure.core/<=","clojure.core/=","clojure.core/==","clojure.core/>","clojure.core/>=","clojure.core/PrintWriter-on","clojure.core/StackTraceElement->vec","clojure.core/Throwable->map","clojure.core/accessor","clojure.core/aclone","clojure.core/add-classpath","clojure.core/add-tap","clojure.core/add-watch","clojure.core/agent","clojure.core/agent-error","clojure.core/agent-errors","clojure.core/aget","clojure.core/alength","clojure.core/alias","clojure.core/all-ns","clojure.core/alter","clojure.core/alter-meta!","clojure.core/alter-var-root","clojure.core/ancestors","clojure.core/any?","clojure.core/apply","clojure.core/array-map","clojure.core/aset","clojure.core/aset-boolean","clojure.core/aset-byte","clojure.core/aset-char","clojure.core/aset-double","clojure.core/aset-float","clojure.core/aset-int","clojure.core/aset-long","clojure.core/aset-short","clojure.core/assoc","clojure.core/assoc!","clojure.core/assoc-in","clojure.core/associative?","clojure.core/atom","clojure.core/await","clojure.core/await-for","clojure.core/await1","clojure.core/bases","clojure.core/bean","clojure.core/bigdec","clojure.core/bigint","clojure.core/biginteger","clojure.core/bit-and","clojure.core/bit-and-not","clojure.core/bit-clear","clojure.core/bit-flip","clojure.core/bit-not","clojure.core/bit-or","clojure.core/bit-set","clojure.core/bit-shift-left","clojure.core/bit-shift-right","clojure.core/bit-test","clojure.core/bit-xor","clojure.core/boolean","clojure.core/boolean-array","clojure.core/boolean?","clojure.core/booleans","clojure.core/bound-fn*","clojure.core/bound?","clojure.core/bounded-count","clojure.core/butlast","clojure.core/byte","clojure.core/byte-array","clojure.core/bytes","clojure.core/bytes?","clojure.core/cast","clojure.core/cat","clojure.core/char","clojure.core/char-array","clojure.core/char?","clojure.core/chars","clojure.core/chunk","clojure.core/chunk-append","clojure.core/chunk-buffer","clojure.core/chunk-cons","clojure.core/chunk-first","clojure.core/chunk-next","clojure.core/chunk-rest","clojure.core/chunked-seq?","clojure.core/class","clojure.core/class?","clojure.core/clear-agent-errors","clojure.core/clojure-version","clojure.core/coll?","clojure.core/commute","clojure.core/comp","clojure.core/comparator","clojure.core/compare","clojure.core/compare-and-set!","clojure.core/compile","clojure.core/complement","clojure.core/completing","clojure.core/concat","clojure.core/conj","clojure.core/conj!","clojure.core/cons","clojure.core/constantly","clojure.core/construct-proxy","clojure.core/contains?","clojure.core/count","clojure.core/counted?","clojure.core/create-ns","clojure.core/create-struct","clojure.core/cycle","clojure.core/dec","clojure.core/dec'","clojure.core/decimal?","clojure.core/dedupe","clojure.core/delay?","clojure.core/deliver","clojure.core/denominator","clojure.core/deref","clojure.core/derive","clojure.core/descendants","clojure.core/destructure","clojure.core/disj","clojure.core/disj!","clojure.core/dissoc","clojure.core/dissoc!","clojure.core/distinct","clojure.core/distinct?","clojure.core/doall","clojure.core/dorun","clojure.core/double","clojure.core/double-array","clojure.core/double?","clojure.core/doubles","clojure.core/drop","clojure.core/drop-last","clojure.core/drop-while","clojure.core/eduction","clojure.core/empty","clojure.core/empty?","clojure.core/ensure","clojure.core/ensure-reduced","clojure.core/enumeration-seq","clojure.core/error-handler","clojure.core/error-mode","clojure.core/eval","clojure.core/even?","clojure.core/every-pred","clojure.core/every?","clojure.core/ex-cause","clojure.core/ex-data","clojure.core/ex-info","clojure.core/ex-message","clojure.core/extend","clojure.core/extenders","clojure.core/extends?","clojure.core/false?","clojure.core/ffirst","clojure.core/file-seq","clojure.core/filter","clojure.core/filterv","clojure.core/find","clojure.core/find-keyword","clojure.core/find-ns","clojure.core/find-protocol-impl","clojure.core/find-protocol-method","clojure.core/find-var","clojure.core/first","clojure.core/flatten","clojure.core/float","clojure.core/float-array","clojure.core/float?","clojure.core/floats","clojure.core/flush","clojure.core/fn?","clojure.core/fnext","clojure.core/fnil","clojure.core/force","clojure.core/format","clojure.core/frequencies","clojure.core/future-call","clojure.core/future-cancel","clojure.core/future-cancelled?","clojure.core/future-done?","clojure.core/future?","clojure.core/gensym","clojure.core/get","clojure.core/get-in","clojure.core/get-method","clojure.core/get-proxy-class","clojure.core/get-thread-bindings","clojure.core/get-validator","clojure.core/group-by","clojure.core/halt-when","clojure.core/hash","clojure.core/hash-combine","clojure.core/hash-map","clojure.core/hash-ordered-coll","clojure.core/hash-set","clojure.core/hash-unordered-coll","clojure.core/ident?","clojure.core/identical?","clojure.core/identity","clojure.core/ifn?","clojure.core/in-ns","clojure.core/inc","clojure.core/inc'","clojure.core/indexed?","clojure.core/init-proxy","clojure.core/inst-ms","clojure.core/inst-ms*","clojure.core/inst?","clojure.core/instance?","clojure.core/int","clojure.core/int-array","clojure.core/int?","clojure.core/integer?","clojure.core/interleave","clojure.core/intern","clojure.core/interpose","clojure.core/into","clojure.core/into-array","clojure.core/ints","clojure.core/isa?","clojure.core/iterate","clojure.core/iterator-seq","clojure.core/juxt","clojure.core/keep","clojure.core/keep-indexed","clojure.core/key","clojure.core/keys","clojure.core/keyword","clojure.core/keyword?","clojure.core/last","clojure.core/line-seq","clojure.core/list","clojure.core/list*","clojure.core/list?","clojure.core/load","clojure.core/load-file","clojure.core/load-reader","clojure.core/load-string","clojure.core/loaded-libs","clojure.core/long","clojure.core/long-array","clojure.core/longs","clojure.core/macroexpand","clojure.core/macroexpand-1","clojure.core/make-array","clojure.core/make-hierarchy","clojure.core/map","clojure.core/map-entry?","clojure.core/map-indexed","clojure.core/map?","clojure.core/mapcat","clojure.core/mapv","clojure.core/max","clojure.core/max-key","clojure.core/memoize","clojure.core/merge","clojure.core/merge-with","clojure.core/meta","clojure.core/method-sig","clojure.core/methods","clojure.core/min","clojure.core/min-key","clojure.core/mix-collection-hash","clojure.core/mod","clojure.core/munge","clojure.core/name","clojure.core/namespace","clojure.core/namespace-munge","clojure.core/nat-int?","clojure.core/neg-int?","clojure.core/neg?","clojure.core/newline","clojure.core/next","clojure.core/nfirst","clojure.core/nil?","clojure.core/nnext","clojure.core/not","clojure.core/not-any?","clojure.core/not-empty","clojure.core/not-every?","clojure.core/not=","clojure.core/ns-aliases","clojure.core/ns-imports","clojure.core/ns-interns","clojure.core/ns-map","clojure.core/ns-name","clojure.core/ns-publics","clojure.core/ns-refers","clojure.core/ns-resolve","clojure.core/ns-unalias","clojure.core/ns-unmap","clojure.core/nth","clojure.core/nthnext","clojure.core/nthrest","clojure.core/num","clojure.core/number?","clojure.core/numerator","clojure.core/object-array","clojure.core/odd?","clojure.core/parents","clojure.core/partial","clojure.core/partition","clojure.core/partition-all","clojure.core/partition-by","clojure.core/pcalls","clojure.core/peek","clojure.core/persistent!","clojure.core/pmap","clojure.core/pop","clojure.core/pop!","clojure.core/pop-thread-bindings","clojure.core/pos-int?","clojure.core/pos?","clojure.core/pr","clojure.core/pr-str","clojure.core/prefer-method","clojure.core/prefers","clojure.core/print","clojure.core/print-ctor","clojure.core/print-dup","clojure.core/print-method","clojure.core/print-simple","clojure.core/print-str","clojure.core/printf","clojure.core/println","clojure.core/println-str","clojure.core/prn","clojure.core/prn-str","clojure.core/promise","clojure.core/proxy-call-with-super","clojure.core/proxy-mappings","clojure.core/proxy-name","clojure.core/push-thread-bindings","clojure.core/qualified-ident?","clojure.core/qualified-keyword?","clojure.core/qualified-symbol?","clojure.core/quot","clojure.core/rand","clojure.core/rand-int","clojure.core/rand-nth","clojure.core/random-sample","clojure.core/range","clojure.core/ratio?","clojure.core/rational?","clojure.core/rationalize","clojure.core/re-find","clojure.core/re-groups","clojure.core/re-matcher","clojure.core/re-matches","clojure.core/re-pattern","clojure.core/re-seq","clojure.core/read","clojure.core/read+string","clojure.core/read-line","clojure.core/read-string","clojure.core/reader-conditional","clojure.core/reader-conditional?","clojure.core/realized?","clojure.core/record?","clojure.core/reduce","clojure.core/reduce-kv","clojure.core/reduced","clojure.core/reduced?","clojure.core/reductions","clojure.core/ref","clojure.core/ref-history-count","clojure.core/ref-max-history","clojure.core/ref-min-history","clojure.core/ref-set","clojure.core/refer","clojure.core/release-pending-sends","clojure.core/rem","clojure.core/remove","clojure.core/remove-all-methods","clojure.core/remove-method","clojure.core/remove-ns","clojure.core/remove-tap","clojure.core/remove-watch","clojure.core/repeat","clojure.core/repeatedly","clojure.core/replace","clojure.core/replicate","clojure.core/require","clojure.core/requiring-resolve","clojure.core/reset!","clojure.core/reset-meta!","clojure.core/reset-vals!","clojure.core/resolve","clojure.core/rest","clojure.core/restart-agent","clojure.core/resultset-seq","clojure.core/reverse","clojure.core/reversible?","clojure.core/rseq","clojure.core/rsubseq","clojure.core/run!","clojure.core/satisfies?","clojure.core/second","clojure.core/select-keys","clojure.core/send","clojure.core/send-off","clojure.core/send-via","clojure.core/seq","clojure.core/seq?","clojure.core/seqable?","clojure.core/seque","clojure.core/sequence","clojure.core/sequential?","clojure.core/set","clojure.core/set-agent-send-executor!","clojure.core/set-agent-send-off-executor!","clojure.core/set-error-handler!","clojure.core/set-error-mode!","clojure.core/set-validator!","clojure.core/set?","clojure.core/short","clojure.core/short-array","clojure.core/shorts","clojure.core/shuffle","clojure.core/shutdown-agents","clojure.core/simple-ident?","clojure.core/simple-keyword?","clojure.core/simple-symbol?","clojure.core/slurp","clojure.core/some","clojure.core/some-fn","clojure.core/some?","clojure.core/sort","clojure.core/sort-by","clojure.core/sorted-map","clojure.core/sorted-map-by","clojure.core/sorted-set","clojure.core/sorted-set-by","clojure.core/sorted?","clojure.core/special-symbol?","clojure.core/spit","clojure.core/split-at","clojure.core/split-with","clojure.core/str","clojure.core/string?","clojure.core/struct","clojure.core/struct-map","clojure.core/subs","clojure.core/subseq","clojure.core/subvec","clojure.core/supers","clojure.core/swap!","clojure.core/swap-vals!","clojure.core/symbol","clojure.core/symbol?","clojure.core/tagged-literal","clojure.core/tagged-literal?","clojure.core/take","clojure.core/take-last","clojure.core/take-nth","clojure.core/take-while","clojure.core/tap>","clojure.core/test","clojure.core/the-ns","clojure.core/thread-bound?","clojure.core/to-array","clojure.core/to-array-2d","clojure.core/trampoline","clojure.core/transduce","clojure.core/transient","clojure.core/tree-seq","clojure.core/true?","clojure.core/type","clojure.core/unchecked-add","clojure.core/unchecked-add-int","clojure.core/unchecked-byte","clojure.core/unchecked-char","clojure.core/unchecked-dec","clojure.core/unchecked-dec-int","clojure.core/unchecked-divide-int","clojure.core/unchecked-double","clojure.core/unchecked-float","clojure.core/unchecked-inc","clojure.core/unchecked-inc-int","clojure.core/unchecked-int","clojure.core/unchecked-long","clojure.core/unchecked-multiply","clojure.core/unchecked-multiply-int","clojure.core/unchecked-negate","clojure.core/unchecked-negate-int","clojure.core/unchecked-remainder-int","clojure.core/unchecked-short","clojure.core/unchecked-subtract","clojure.core/unchecked-subtract-int","clojure.core/underive","clojure.core/unreduced","clojure.core/unsigned-bit-shift-right","clojure.core/update","clojure.core/update-in","clojure.core/update-proxy","clojure.core/uri?","clojure.core/use","clojure.core/uuid?","clojure.core/val","clojure.core/vals","clojure.core/var-get","clojure.core/var-set","clojure.core/var?","clojure.core/vary-meta","clojure.core/vec","clojure.core/vector","clojure.core/vector-of","clojure.core/vector?","clojure.core/volatile!","clojure.core/volatile?","clojure.core/vreset!","clojure.core/with-bindings*","clojure.core/with-meta","clojure.core/with-redefs-fn","clojure.core/xml-seq","clojure.core/zero?","clojure.core/zipmap","coll?","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","conj","conj!","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","dedupe","delay?","deliver","denominator","deref","derive","descendants","destructure","disj","disj!","dissoc","dissoc!","distinct","distinct?","doall","dorun","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-cause","ex-data","ex-info","ex-message","extend","extenders","extends?","false?","ffirst","file-seq","filter","filterv","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn?","fnext","fnil","force","format","frequencies","future-call","future-cancel","future-cancelled?","future-done?","future?","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","ifn?","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","long","long-array","longs","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop","pop!","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy-call-with-super","proxy-mappings","proxy-name","push-thread-bindings","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read+string","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-tap","remove-watch","repeat","repeatedly","replace","replicate","require","requiring-resolve","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","tap>","test","the-ns","thread-bound?","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","with-bindings*","with-meta","with-redefs-fn","xml-seq","zero?","zipmap"],
+ \ 'clojureMacro': ["->","->>","..","amap","and","areduce","as->","assert","binding","bound-fn","clojure.core/->","clojure.core/->>","clojure.core/..","clojure.core/amap","clojure.core/and","clojure.core/areduce","clojure.core/as->","clojure.core/assert","clojure.core/binding","clojure.core/bound-fn","clojure.core/comment","clojure.core/declare","clojure.core/delay","clojure.core/dosync","clojure.core/doto","clojure.core/extend-protocol","clojure.core/extend-type","clojure.core/for","clojure.core/future","clojure.core/gen-class","clojure.core/gen-interface","clojure.core/import","clojure.core/io!","clojure.core/lazy-cat","clojure.core/lazy-seq","clojure.core/locking","clojure.core/memfn","clojure.core/ns","clojure.core/or","clojure.core/proxy","clojure.core/proxy-super","clojure.core/pvalues","clojure.core/refer-clojure","clojure.core/reify","clojure.core/some->","clojure.core/some->>","clojure.core/sync","clojure.core/time","clojure.core/vswap!","clojure.core/with-bindings","clojure.core/with-in-str","clojure.core/with-loading-context","clojure.core/with-local-vars","clojure.core/with-open","clojure.core/with-out-str","clojure.core/with-precision","clojure.core/with-redefs","comment","declare","delay","dosync","doto","extend-protocol","extend-type","for","future","gen-class","gen-interface","import","io!","lazy-cat","lazy-seq","locking","memfn","ns","or","proxy","proxy-super","pvalues","refer-clojure","reify","some->","some->>","sync","time","vswap!","with-bindings","with-in-str","with-loading-context","with-local-vars","with-open","with-out-str","with-precision","with-redefs"],
+ \ 'clojureRepeat': ["clojure.core/doseq","clojure.core/dotimes","clojure.core/loop","clojure.core/while","doseq","dotimes","loop","loop*","recur","while"],
+ \ 'clojureSpecial': ["&",".","clojure.core/fn","clojure.core/import*","clojure.core/let","clojure.core/letfn","do","fn","fn*","let","let*","letfn","letfn*","monitor-enter","monitor-exit","new","quote","reify*","set!","var"],
+ \ 'clojureVariable': ["*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","EMPTY-NODE","Inst","char-escape-string","char-name-string","clojure.core/*1","clojure.core/*2","clojure.core/*3","clojure.core/*agent*","clojure.core/*allow-unresolved-vars*","clojure.core/*assert*","clojure.core/*clojure-version*","clojure.core/*command-line-args*","clojure.core/*compile-files*","clojure.core/*compile-path*","clojure.core/*compiler-options*","clojure.core/*data-readers*","clojure.core/*default-data-reader-fn*","clojure.core/*e","clojure.core/*err*","clojure.core/*file*","clojure.core/*flush-on-newline*","clojure.core/*fn-loader*","clojure.core/*in*","clojure.core/*math-context*","clojure.core/*ns*","clojure.core/*out*","clojure.core/*print-dup*","clojure.core/*print-length*","clojure.core/*print-level*","clojure.core/*print-meta*","clojure.core/*print-namespace-maps*","clojure.core/*print-readably*","clojure.core/*read-eval*","clojure.core/*reader-resolver*","clojure.core/*source-path*","clojure.core/*suppress-read*","clojure.core/*unchecked-math*","clojure.core/*use-context-classloader*","clojure.core/*verbose-defrecords*","clojure.core/*warn-on-reflection*","clojure.core/EMPTY-NODE","clojure.core/Inst","clojure.core/char-escape-string","clojure.core/char-name-string","clojure.core/default-data-readers","clojure.core/primitives-classnames","clojure.core/print-dup","clojure.core/print-method","clojure.core/unquote","clojure.core/unquote-splicing","default-data-readers","primitives-classnames","print-dup","print-method","unquote","unquote-splicing"]
+ \ }
function! s:syntax_keyword(dict)
for key in keys(a:dict)
@@ -85,8 +85,6 @@ syntax match clojureSymbol "\v%([a-zA-Z!$&*_+=|<.>?-]|[^\x00-\x7F])+%(:?%([a-zA-
" NB. Correct matching of radix literals was removed for better performance.
syntax match clojureNumber "\v<[-+]?%(%([2-9]|[12]\d|3[0-6])[rR][[:alnum:]]+|%(0\o*|0x\x+|[1-9]\d*)N?|%(0|[1-9]\d*|%(0|[1-9]\d*)\.\d*)%(M|[eE][-+]?\d+)?|%(0|[1-9]\d*)/%(0|[1-9]\d*))>"
-syntax match clojureVarArg "&"
-
syntax match clojureQuote "\v['`]"
syntax match clojureUnquote "\v\~\@?"
syntax match clojureMeta "\^"
@@ -102,7 +100,7 @@ syntax region clojureRegexpQuote start=/\\Q/ skip=/\\\\\|\\"/ end=/\\E/
" -*- CHARACTER PROPERTY CLASSES -*-
" Generated from https://github.com/clojure-vim/clojure.vim/blob/%%RELEASE_TAG%%/clj/src/vim_clojure_static/generate.clj
-" Java version 17
+" Java version 17.0.2
syntax match clojureRegexpPosixCharClass "\v\\[pP]\{%(Cntrl|A%(l%(pha|num)|SCII)|Space|Graph|Upper|P%(rint|unct)|Blank|XDigit|Digit|Lower)\}" contained display
syntax match clojureRegexpJavaCharClass "\v\\[pP]\{java%(Whitespace|JavaIdentifier%(Part|Start)|SpaceChar|Mirrored|TitleCase|I%(SOControl|de%(ographic|ntifierIgnorable))|D%(efined|igit)|U%(pperCase|nicodeIdentifier%(Part|Start))|L%(etter%(OrDigit)?|owerCase)|Alphabetic)\}" contained display
syntax match clojureRegexpUnicodeCharClass "\v\\[pP]\{\cIs%(l%(owercase|etter)|hex%(digit|_digit)|w%(hite%(_space|space)|ord)|noncharacter%(_code_point|codepoint)|p%(rint|unctuation)|ideographic|graph|a%(l%(num|phabetic)|ssigned)|uppercase|join%(control|_control)|titlecase|blank|digit|control)\}" contained display
@@ -131,7 +129,7 @@ syntax match clojureRegexpMod "\v\(@<=\?%(\<?[=!]|\>)" contained display
syntax match clojureRegexpMod "\v\(@<=\?\<[[:alpha:]]+\>" contained display
syntax region clojureRegexpGroup start="(" skip=/\\\\\|\\)/ end=")" matchgroup=clojureRegexpGroup contained contains=clojureRegexpMod,clojureRegexpQuantifier,clojureRegexpBoundary,clojureRegexpEscape,@clojureRegexpCharClasses
-syntax region clojureRegexp start=/\#"/ skip=/\\\\\|\\"/ end=/"/ contains=@clojureRegexpCharClasses,clojureRegexpEscape,clojureRegexpQuote,clojureRegexpBoundary,clojureRegexpQuantifier,clojureRegexpOr,clojureRegexpBackRef,clojureRegexpGroup keepend
+syntax region clojureRegexp matchgroup=clojureRegexpDelimiter start=/\#"/ skip=/\\\\\|\\"/ end=/"/ contains=@clojureRegexpCharClasses,clojureRegexpEscape,clojureRegexpQuote,clojureRegexpBoundary,clojureRegexpQuantifier,clojureRegexpOr,clojureRegexpBackRef,clojureRegexpGroup keepend
syntax keyword clojureCommentTodo contained FIXME XXX TODO BUG NOTE HACK FIXME: XXX: TODO: BUG: NOTE: HACK:
@@ -154,7 +152,7 @@ endif
" -*- TOP CLUSTER -*-
" Generated from https://github.com/clojure-vim/clojure.vim/blob/%%RELEASE_TAG%%/clj/src/vim_clojure_static/generate.clj
-syntax cluster clojureTop contains=@Spell,clojureAnonArg,clojureBoolean,clojureCharacter,clojureComment,clojureCond,clojureConstant,clojureDefine,clojureDeref,clojureDiscard,clojureDispatch,clojureError,clojureException,clojureFunc,clojureKeyword,clojureMacro,clojureMap,clojureMeta,clojureNumber,clojureQuote,clojureRegexp,clojureRepeat,clojureSexp,clojureSpecial,clojureString,clojureSymbol,clojureUnquote,clojureVarArg,clojureVariable,clojureVector
+syntax cluster clojureTop contains=@Spell,clojureAnonArg,clojureBoolean,clojureCharacter,clojureComment,clojureCond,clojureConstant,clojureDefine,clojureDeref,clojureDiscard,clojureDispatch,clojureError,clojureException,clojureFunc,clojureKeyword,clojureMacro,clojureMap,clojureMeta,clojureNumber,clojureQuote,clojureRegexp,clojureRepeat,clojureSexp,clojureSpecial,clojureString,clojureSymbol,clojureUnquote,clojureVariable,clojureVector
syntax region clojureSexp matchgroup=clojureParen start="(" end=")" contains=@clojureTop fold
syntax region clojureVector matchgroup=clojureParen start="\[" end="]" contains=@clojureTop fold
@@ -175,6 +173,7 @@ highlight default link clojureStringDelimiter String
highlight default link clojureStringEscape Character
highlight default link clojureRegexp Constant
+highlight default link clojureRegexpDelimiter Constant
highlight default link clojureRegexpEscape Character
highlight default link clojureRegexpCharClass SpecialChar
highlight default link clojureRegexpPosixCharClass clojureRegexpCharClass
@@ -199,7 +198,6 @@ highlight default link clojureMacro Macro
highlight default link clojureRepeat Repeat
highlight default link clojureSpecial Special
-highlight default link clojureVarArg Special
highlight default link clojureQuote SpecialChar
highlight default link clojureUnquote SpecialChar
highlight default link clojureMeta SpecialChar
diff --git a/syntax/crystal.vim b/syntax/crystal.vim
index ea862acd..ebac0b23 100644
--- a/syntax/crystal.vim
+++ b/syntax/crystal.vim
@@ -380,13 +380,14 @@ syn cluster crystalMacroGroup add=crystalMacroKeyword
" Comments and Documentation
syn match crystalSharpBang "\%^#!.*" display
syn keyword crystalTodo FIXME NOTE TODO OPTIMIZE XXX todo contained
+syn match crystalCommentDirective ":\%(nodoc\|nodoc\|inherit\):" contained
if exists('g:main_syntax') && g:main_syntax ==# 'ecrystal'
" eCrystal tags can contain Crystal comments, so we need to modify the
" pattern for comments so that it does not consume delimiters
- syn match crystalComment "#.*\ze\%($\|-\=%>\)" contains=crystalSharpBang,crystalSpaceError,crystalTodo,@Spell
+ syn match crystalComment "#.*\ze\%($\|-\=%>\)" contains=crystalSharpBang,crystalSpaceError,crystalTodo,crystalCommentDirective,@Spell
else
- syn match crystalComment "#.*" contains=crystalSharpBang,crystalSpaceError,crystalTodo,@Spell
+ syn match crystalComment "#.*" contains=crystalSharpBang,crystalSpaceError,crystalTodo,crystalCommentDirective,@Spell
endif
SynFold '#' syn region crystalMultilineComment start="\%(\%(^\s*#.*\n\)\@<!\%(^\s*#.*\n\)\)\%(\(^\s*#.*\n\)\{1,}\)\@=" end="\%(^\s*#.*\n\)\@<=\%(^\s*#.*\n\)\%(^\s*#\)\@!" contains=crystalComment transparent keepend
@@ -456,6 +457,7 @@ hi def link crystalPseudoVariable Constant
hi def link crystalCharLiteral Character
hi def link crystalComment Comment
hi def link crystalTodo Todo
+hi def link crystalCommentDirective SpecialComment
hi def link crystalStringEscape Special
hi def link crystalInterpolationDelim Delimiter
hi def link crystalNoInterpolation crystalString
diff --git a/syntax/eelixir.vim b/syntax/eelixir.vim
index 8fbe92a7..0b8669bf 100644
--- a/syntax/eelixir.vim
+++ b/syntax/eelixir.vim
@@ -63,6 +63,8 @@ syn cluster eelixirRegions contains=eelixirBlock,surfaceExpression,eelixirExpres
exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%=" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{{" end="}}" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
+exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{" end="}" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
+exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{" end="}" skip="#{[^}]*}" contains=@elixirTop containedin=htmlValue keepend'
exe 'syn region eelixirQuote matchgroup=eelixirDelimiter start="<%%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region eelixirComment matchgroup=eelixirDelimiter start="<%#" end="%\@<!%>" contains=elixirTodo,@Spell containedin=ALLBUT,@eelixirRegions keepend'
diff --git a/syntax/glsl.vim b/syntax/glsl.vim
index 34230a91..65833168 100644
--- a/syntax/glsl.vim
+++ b/syntax/glsl.vim
@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'glsl', 'syntax/glsl.vim')
endif
" Language: OpenGL Shading Language
-" Maintainer: Sergey Tikhomirov <sergey@tikhomirov.io>
+" Maintainer: Sergii Tykhomyrov <sergii@tykhomyrov.net>
if exists("b:current_syntax") && b:current_syntax == "glsl"
finish
@@ -51,6 +51,7 @@ syn keyword glslStructure struct nextgroup=glslIdentifier skipwhite skipempty
syn match glslIdentifier contains=glslIdentifierPrime "\%([a-zA-Z_]\)\%([a-zA-Z0-9_]\)*" display contained
" Types
+syn keyword glslType accelerationStructureEXT
syn keyword glslType atomic_uint
syn keyword glslType bool
syn keyword glslType bvec2
@@ -122,6 +123,7 @@ syn keyword glslType mat4
syn keyword glslType mat4x2
syn keyword glslType mat4x3
syn keyword glslType mat4x4
+syn keyword glslType rayQueryEXT
syn keyword glslType sampler1D
syn keyword glslType sampler1DArray
syn keyword glslType sampler1DArrayShadow
@@ -176,6 +178,8 @@ syn keyword glslQualifier align
syn keyword glslQualifier attribute
syn keyword glslQualifier binding
syn keyword glslQualifier buffer
+syn keyword glslQualifier callableDataEXT
+syn keyword glslQualifier callableDataInEXT
syn keyword glslQualifier ccw
syn keyword glslQualifier centroid
syn keyword glslQualifier centroid varying
@@ -193,6 +197,7 @@ syn keyword glslQualifier flat
syn keyword glslQualifier fractional_even_spacing
syn keyword glslQualifier fractional_odd_spacing
syn keyword glslQualifier highp
+syn keyword glslQualifier hitAttributeEXT
syn keyword glslQualifier in
syn keyword glslQualifier index
syn keyword glslQualifier inout
@@ -210,6 +215,7 @@ syn keyword glslQualifier location
syn keyword glslQualifier lowp
syn keyword glslQualifier max_vertices
syn keyword glslQualifier mediump
+syn keyword glslQualifier nonuniformEXT
syn keyword glslQualifier noperspective
syn keyword glslQualifier offset
syn keyword glslQualifier origin_upper_left
@@ -235,6 +241,8 @@ syn keyword glslQualifier r8
syn keyword glslQualifier r8_snorm
syn keyword glslQualifier r8i
syn keyword glslQualifier r8ui
+syn keyword glslQualifier rayPayloadEXT
+syn keyword glslQualifier rayPayloadInEXT
syn keyword glslQualifier readonly
syn keyword glslQualifier restrict
syn keyword glslQualifier rg16
@@ -265,6 +273,7 @@ syn keyword glslQualifier rgba8i
syn keyword glslQualifier rgba8ui
syn keyword glslQualifier row_major
syn keyword glslQualifier sample
+syn keyword glslQualifier shaderRecordEXT
syn keyword glslQualifier shared
syn keyword glslQualifier smooth
syn keyword glslQualifier std140
@@ -279,11 +288,13 @@ syn keyword glslQualifier vertices
syn keyword glslQualifier volatile
syn keyword glslQualifier writeonly
syn keyword glslQualifier xfb_buffer
-syn keyword glslQualifier xfb_stride
syn keyword glslQualifier xfb_offset
+syn keyword glslQualifier xfb_stride
" Built-in Constants
syn keyword glslBuiltinConstant gl_CullDistance
+syn keyword glslBuiltinConstant gl_HitKindBackFacingTriangleEXT
+syn keyword glslBuiltinConstant gl_HitKindFrontFacingTriangleEXT
syn keyword glslBuiltinConstant gl_MaxAtomicCounterBindings
syn keyword glslBuiltinConstant gl_MaxAtomicCounterBufferSize
syn keyword glslBuiltinConstant gl_MaxClipDistances
@@ -363,6 +374,20 @@ syn keyword glslBuiltinConstant gl_MaxVertexUniformComponents
syn keyword glslBuiltinConstant gl_MaxVertexUniformVectors
syn keyword glslBuiltinConstant gl_MaxViewports
syn keyword glslBuiltinConstant gl_MinProgramTexelOffset
+syn keyword glslBuiltinConstant gl_RayFlagsCullBackFacingTrianglesEXT
+syn keyword glslBuiltinConstant gl_RayFlagsCullFrontFacingTrianglesEXT
+syn keyword glslBuiltinConstant gl_RayFlagsCullNoOpaqueEXT
+syn keyword glslBuiltinConstant gl_RayFlagsCullOpaqueEXT
+syn keyword glslBuiltinConstant gl_RayFlagsNoOpaqueEXT
+syn keyword glslBuiltinConstant gl_RayFlagsNoneEXT
+syn keyword glslBuiltinConstant gl_RayFlagsOpaqueEXT
+syn keyword glslBuiltinConstant gl_RayFlagsSkipClosestHitShaderEXT
+syn keyword glslBuiltinConstant gl_RayFlagsTerminateOnFirstHitEXT
+syn keyword glslBuiltinConstant gl_RayQueryCandidateIntersectionAABBEXT
+syn keyword glslBuiltinConstant gl_RayQueryCandidateIntersectionTriangleEXT
+syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionGeneratedEXT
+syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionNoneEXT
+syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionTriangleEXT
" Built-in Variables
syn keyword glslBuiltinVariable gl_BackColor
@@ -393,10 +418,18 @@ syn keyword glslBuiltinVariable gl_FrontLightModelProduct
syn keyword glslBuiltinVariable gl_FrontLightProduct
syn keyword glslBuiltinVariable gl_FrontMaterial
syn keyword glslBuiltinVariable gl_FrontSecondaryColor
+syn keyword glslBuiltinVariable gl_GeometryIndexEXT
syn keyword glslBuiltinVariable gl_GlobalInvocationID
syn keyword glslBuiltinVariable gl_HelperInvocation
+syn keyword glslBuiltinVariable gl_HitKindEXT
+syn keyword glslBuiltinVariable gl_HitTEXT
+syn keyword glslBuiltinVariable gl_IncomingRayFlagsEXT
+syn keyword glslBuiltinVariable gl_InstanceCustomIndexEXT
+syn keyword glslBuiltinVariable gl_InstanceID
syn keyword glslBuiltinVariable gl_InstanceID
syn keyword glslBuiltinVariable gl_InvocationID
+syn keyword glslBuiltinVariable gl_LaunchIDEXT
+syn keyword glslBuiltinVariable gl_LaunchSizeEXT
syn keyword glslBuiltinVariable gl_Layer
syn keyword glslBuiltinVariable gl_LightModel
syn keyword glslBuiltinVariable gl_LightSource
@@ -427,17 +460,24 @@ syn keyword glslBuiltinVariable gl_ObjectPlaneQ
syn keyword glslBuiltinVariable gl_ObjectPlaneR
syn keyword glslBuiltinVariable gl_ObjectPlaneS
syn keyword glslBuiltinVariable gl_ObjectPlaneT
+syn keyword glslBuiltinVariable gl_ObjectRayDirectionEXT
+syn keyword glslBuiltinVariable gl_ObjectRayOriginEXT
+syn keyword glslBuiltinVariable gl_ObjectToWorld3x4EXT
+syn keyword glslBuiltinVariable gl_ObjectToWorldEXT
syn keyword glslBuiltinVariable gl_PatchVerticesIn
syn keyword glslBuiltinVariable gl_Point
syn keyword glslBuiltinVariable gl_PointCoord
syn keyword glslBuiltinVariable gl_PointSize
syn keyword glslBuiltinVariable gl_Position
syn keyword glslBuiltinVariable gl_PrimitiveID
+syn keyword glslBuiltinVariable gl_PrimitiveID
syn keyword glslBuiltinVariable gl_PrimitiveIDIn
syn keyword glslBuiltinVariable gl_ProjectionMatrix
syn keyword glslBuiltinVariable gl_ProjectionMatrixInverse
syn keyword glslBuiltinVariable gl_ProjectionMatrixInverseTranspose
syn keyword glslBuiltinVariable gl_ProjectionMatrixTranspose
+syn keyword glslBuiltinVariable gl_RayTmaxEXT
+syn keyword glslBuiltinVariable gl_RayTminEXT
syn keyword glslBuiltinVariable gl_SampleID
syn keyword glslBuiltinVariable gl_SampleMask
syn keyword glslBuiltinVariable gl_SampleMaskIn
@@ -458,6 +498,10 @@ syn keyword glslBuiltinVariable gl_VertexIndex
syn keyword glslBuiltinVariable gl_ViewportIndex
syn keyword glslBuiltinVariable gl_WorkGroupID
syn keyword glslBuiltinVariable gl_WorkGroupSize
+syn keyword glslBuiltinVariable gl_WorldRayDirectionEXT
+syn keyword glslBuiltinVariable gl_WorldRayOriginEXT
+syn keyword glslBuiltinVariable gl_WorldToObject3x4EXT
+syn keyword glslBuiltinVariable gl_WorldToObjectEXT
syn keyword glslBuiltinVariable gl_in
syn keyword glslBuiltinVariable gl_out
@@ -507,6 +551,7 @@ syn keyword glslBuiltinFunction determinant
syn keyword glslBuiltinFunction distance
syn keyword glslBuiltinFunction dot
syn keyword glslBuiltinFunction equal
+syn keyword glslBuiltinFunction executeCallableEXT
syn keyword glslBuiltinFunction exp
syn keyword glslBuiltinFunction exp2
syn keyword glslBuiltinFunction faceforward
@@ -525,6 +570,7 @@ syn keyword glslBuiltinFunction fwidthFine
syn keyword glslBuiltinFunction greaterThan
syn keyword glslBuiltinFunction greaterThanEqual
syn keyword glslBuiltinFunction groupMemoryBarrier
+syn keyword glslBuiltinFunction ignoreIntersectionEXT
syn keyword glslBuiltinFunction imageAtomicAdd
syn keyword glslBuiltinFunction imageAtomicAnd
syn keyword glslBuiltinFunction imageAtomicCompSwap
@@ -578,8 +624,32 @@ syn keyword glslBuiltinFunction packUnorm2x16
syn keyword glslBuiltinFunction packUnorm4x8
syn keyword glslBuiltinFunction pow
syn keyword glslBuiltinFunction radians
+syn keyword glslBuiltinFunction rayQueryConfirmIntersectionEXT
+syn keyword glslBuiltinFunction rayQueryGenerateIntersectionEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionBarycentricsEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionCandidateAABBOpaqueEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionFrontFaceEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionGeometryIndexEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceCustomIndexEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceIdEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectRayDirectionEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectRayOriginEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectToWorldEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionPrimitiveIndexEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionTEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionTypeEXT
+syn keyword glslBuiltinFunction rayQueryGetIntersectionWorldToObjectEXT
+syn keyword glslBuiltinFunction rayQueryGetRayFlagsEXT
+syn keyword glslBuiltinFunction rayQueryGetRayTMinEXT
+syn keyword glslBuiltinFunction rayQueryGetWorldRayDirectionEXT
+syn keyword glslBuiltinFunction rayQueryGetWorldRayOriginEXT
+syn keyword glslBuiltinFunction rayQueryInitializeEXT
+syn keyword glslBuiltinFunction rayQueryProceedEXT
+syn keyword glslBuiltinFunction rayQueryTerminateEXT
syn keyword glslBuiltinFunction reflect
syn keyword glslBuiltinFunction refract
+syn keyword glslBuiltinFunction reportIntersectionEXT
syn keyword glslBuiltinFunction round
syn keyword glslBuiltinFunction roundEven
syn keyword glslBuiltinFunction shadow1D
@@ -598,6 +668,7 @@ syn keyword glslBuiltinFunction sqrt
syn keyword glslBuiltinFunction step
syn keyword glslBuiltinFunction tan
syn keyword glslBuiltinFunction tanh
+syn keyword glslBuiltinFunction terminateRayEXT
syn keyword glslBuiltinFunction texelFetch
syn keyword glslBuiltinFunction texelFetchOffset
syn keyword glslBuiltinFunction texture
@@ -632,6 +703,7 @@ syn keyword glslBuiltinFunction textureProjOffset
syn keyword glslBuiltinFunction textureQueryLevels
syn keyword glslBuiltinFunction textureQueryLod
syn keyword glslBuiltinFunction textureSize
+syn keyword glslBuiltinFunction traceRayEXT
syn keyword glslBuiltinFunction transpose
syn keyword glslBuiltinFunction trunc
syn keyword glslBuiltinFunction uaddCarry
diff --git a/syntax/go.vim b/syntax/go.vim
index c4861715..19763ee0 100644
--- a/syntax/go.vim
+++ b/syntax/go.vim
@@ -38,7 +38,7 @@ hi def link goLabel Label
hi def link goRepeat Repeat
" Predefined types
-syn keyword goType chan map bool string error
+syn keyword goType chan map bool string error any comparable
syn keyword goSignedInts int int8 int16 int32 int64 rune
syn keyword goUnsignedInts byte uint uint8 uint16 uint32 uint64 uintptr
syn keyword goFloats float32 float64
diff --git a/syntax/julia.vim b/syntax/julia.vim
index bafae9b4..3d02d5ed 100644
--- a/syntax/julia.vim
+++ b/syntax/julia.vim
@@ -44,7 +44,7 @@ let s:julia_highlight_operators = get(g:, "julia_highlight_operators", 1)
" because those may or may not be valid in the lookbehind on a case-by-case
" basis.
let s:nonid_chars = '\U00-\U08' . '\U0A-\U1F'
- \ . '\U21-\U28' . '\U2A-\U2F' . '\U3A-\U40' . '\U5B-\U5E' . '\U60' . '\U7B\U7C'
+ \ . '\U21-\U28' . '\U2A-\U2F' . '\U3A-\U40' . '\U5B\U5C\U5E' . '\U60' . '\U7B\U7C'
\ . '\U7E-\UA1' . '\UA7\UA8' . '\UAB-\UAD' . '\UAF\UB1\UB4' . '\UB6-\UB8' . '\UBB\UBF' . '\UD7\UF7'
" The complete list
diff --git a/syntax/markdown.vim b/syntax/markdown.vim
index eeda03da..2c4d7951 100644
--- a/syntax/markdown.vim
+++ b/syntax/markdown.vim
@@ -11,7 +11,7 @@ endif
" Read the HTML syntax to start with
-if version < 600
+if v:version < 600
so <sfile>:p:h/html.vim
else
runtime! syntax/html.vim
@@ -21,14 +21,14 @@ else
endif
endif
-if version < 600
+if v:version < 600
syntax clear
-elseif exists("b:current_syntax")
+elseif exists('b:current_syntax')
finish
endif
" don't use standard HiLink, it will not work with included syntax files
-if version < 508
+if v:version < 508
command! -nargs=+ HtmlHiLink hi link <args>
else
command! -nargs=+ HtmlHiLink hi def link <args>
@@ -182,7 +182,7 @@ HtmlHiLink mkdLinkDefTarget mkdURL
HtmlHiLink mkdLinkTitle htmlString
HtmlHiLink mkdDelimiter Delimiter
-let b:current_syntax = "mkd"
+let b:current_syntax = 'mkd'
delcommand HtmlHiLink
" vim: ts=8
diff --git a/syntax/mermaid.vim b/syntax/mermaid.vim
index 91b8658e..4d9bee26 100644
--- a/syntax/mermaid.vim
+++ b/syntax/mermaid.vim
@@ -4,7 +4,7 @@ endif
setlocal iskeyword+=-
-syntax keyword mermaidDiagramType classDiagram classDiagram-v2 erDiagram gantt graph flowchart pie sequenceDiagram stateDiagram stateDiagram-v2
+syntax keyword mermaidDiagramType classDiagram classDiagram-v2 erDiagram gantt graph flowchart pie sequenceDiagram stateDiagram stateDiagram-v2 gitGraph
syntax match mermaidOperator /\v(-|\<|\>|\+|\||\=)/
syntax match mermaidComment /\v^(\s?)+\%\%.*$/
syntax region mermaidString start=/"/ end=/"/ skip=/\\"/
@@ -35,6 +35,9 @@ syntax match mermaidClassFunction /\v\w+\(((\w+|\s+|\~)?,?)+\)/ contains=ALLBUT,
syntax match mermaidStateFinalKeyword /\[\*\]/
syntax match mermaidStateKeyword /\v(\s+as[^a-z]|^\s+state)/
+syntax match mermaidGitOption /\v^(options|end)/
+syntax match mermaidGitCommands /\v^(commit|branch|merge|reset|checkout)/
+
" TODO highlight gantt keywords
" TODO improve er operators
@@ -63,3 +66,6 @@ highlight link mermaidStateFinalKeyword Keyword
highlight link mermaidStateKeyword Keyword
highlight link mermaidErOperator Operator
+
+highlight link mermaidGitOption Keyword
+highlight link mermaidGitCommands Keyword
diff --git a/syntax/odin.vim b/syntax/odin.vim
index ed09f607..9f8521ae 100644
--- a/syntax/odin.vim
+++ b/syntax/odin.vim
@@ -34,6 +34,9 @@ syntax keyword odinTypeIdOf typeid_of
syntax keyword odinTypeOf type_of
syntax keyword odinAlignOf align_of
+syntax keyword odinOrReturn or_return
+syntax keyword odinOrElse or_else
+
syntax keyword odinInline inline
syntax keyword odinNoInline no_inline
@@ -116,6 +119,8 @@ highlight link odinTypeInfoOf Keyword
highlight link odinTypeIdOf Keyword
highlight link odinAlignOf Keyword
highlight link odinPackage Keyword
+highlight link odinOrReturn Keyword
+highlight link odinOrElse Keyword
highlight link odinInline Keyword
highlight link odinNoInline Keyword
diff --git a/syntax/opam.vim b/syntax/opam.vim
index 21ffb0ff..fca9c02a 100644
--- a/syntax/opam.vim
+++ b/syntax/opam.vim
@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'ocaml', 'syntax/opam.vim')
endif
" Vim syntax file
-" Language: OPAM - OCaml package manager
+" Language: opam - OCaml package manager
" Maintainer: Markus Mottl <markus.mottl@gmail.com>
" URL: https://github.com/ocaml/vim-ocaml
" Last Change:
@@ -15,8 +15,36 @@ endif
" need %{vars}%
" env: [[CAML_LD_LIBRARY_PATH = "%{lib}%/stublibs"]]
-syn keyword opamKeyword1 remove depends pin-depends depopts conflicts env packages patches version maintainer tags license homepage authors doc install author available name depexts substs synopsis description
-syn match opamKeyword2 "\v(bug-reports|post-messages|ocaml-version|opam-version|dev-repo|build-test|build-doc|build)"
+syn keyword opamKeyword1 author
+syn keyword opamKeyword1 authors
+syn keyword opamKeyword1 available
+syn keyword opamKeyword1 conflicts
+syn keyword opamKeyword1 depends
+syn keyword opamKeyword1 depexts
+syn keyword opamKeyword1 depopts
+syn keyword opamKeyword1 description
+syn keyword opamKeyword1 doc
+syn keyword opamKeyword1 extra-files
+syn keyword opamKeyword1 features
+syn keyword opamKeyword1 flags
+syn keyword opamKeyword1 homepage
+syn keyword opamKeyword1 install
+syn keyword opamKeyword1 libraries
+syn keyword opamKeyword1 license
+syn keyword opamKeyword1 maintainer
+syn keyword opamKeyword1 messages
+syn keyword opamKeyword1 name
+syn keyword opamKeyword1 patches
+syn keyword opamKeyword1 pin-depends
+syn keyword opamKeyword1 remove
+syn keyword opamKeyword1 run-test
+syn keyword opamKeyword1 setenv
+syn keyword opamKeyword1 substs
+syn keyword opamKeyword1 synopsis
+syn keyword opamKeyword1 syntax
+syn keyword opamKeyword1 tags
+syn keyword opamKeyword1 version
+syn match opamKeyword2 "\v(bug-reports|post-messages|opam-version|dev-repo|build)"
syn keyword opamTodo FIXME NOTE NOTES TODO XXX contained
syn match opamComment "#.*$" contains=opamTodo,@Spell
diff --git a/syntax/plantuml.vim b/syntax/plantuml.vim
index 701cd99a..6e8ecf2d 100644
--- a/syntax/plantuml.vim
+++ b/syntax/plantuml.vim
@@ -5,10 +5,9 @@ endif
scriptencoding utf-8
" Vim syntax file
" Language: PlantUML
-" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE
if exists('b:current_syntax')
- " finish
+ finish
endif
if v:version < 600
@@ -22,14 +21,16 @@ let b:current_syntax = 'plantuml'
syntax sync minlines=100
-syntax match plantumlPreProc /\%(\%(^@start\|^@end\)\%(dot\|mindmap\|uml\|salt\|wbs\|gantt\)\)\|!\%(define\|definelong\|else\|enddefinelong\|endif\|exit\|if\|ifdef\|ifndef\|include\|pragma\|undef\|gantt\)\s*.*/ contains=plantumlDir
+syntax match plantumlPreProc /\%(^@start\|^@end\)\%(board\|bpm\|creole\|cute\|def\|ditaa\|dot\|flow\|gantt\|git\|jcckit\|json\|latex\|math\|mindmap\|nwdiag\|project\|salt\|tree\|uml\|wbs\|wire\|yaml\)/
+syntax match plantumlPreProc /!\%(assert\|define\|definelong\|dump_memory\|else\|enddefinelong\|endfunction\|endif\|endprocedure\|endsub\|exit\|function\|if\|ifdef\|ifndef\|import\|include\|local\|log\|pragma\|procedure\|return\|startsub\|theme\|undef\|unquoted\)\s*.*/ contains=plantumlDir
syntax region plantumlDir start=/\s\+/ms=s+1 end=/$/ contained
" type
" From 'java - jar plantuml.jar - language' results {{{
-syntax keyword plantumlTypeKeyword abstract actor agent archimate artifact boundary card cloud component control
-syntax keyword plantumlTypeKeyword database detach diamond entity enum file folder frame node object package
-syntax keyword plantumlTypeKeyword participant queue rectangle stack state storage usecase
+syntax keyword plantumlTypeKeyword abstract actor agent annotation archimate artifact boundary card cloud
+syntax keyword plantumlTypeKeyword collections component control database diamond entity enum file folder frame
+syntax keyword plantumlTypeKeyword hexagon label node object package participant person queue rectangle stack state
+syntax keyword plantumlTypeKeyword storage usecase
" class and interface are defined as plantumlClassKeyword
syntax keyword plantumlClassKeyword class interface
"}}}
@@ -38,13 +39,16 @@ syntax keyword plantumlTypeKeyword concise robust
" keyword
" From 'java - jar plantuml.jar - language' results {{{
-" Since "syntax keyword" can handle only words, "top to bottom direction" is excluded.
-syntax keyword plantumlKeyword accross activate again allow_mixing allowmixing also alt as autonumber bottom
-syntax keyword plantumlKeyword box break caption center create critical deactivate destroy down else elseif end
-syntax keyword plantumlKeyword endif endwhile footbox footer fork group header hide hnote if is kill left
-syntax keyword plantumlKeyword legend link loop mainframe namespace newpage note of on opt order over package
-syntax keyword plantumlKeyword page par partition ref repeat return right rnote rotate show skin skinparam
-syntax keyword plantumlKeyword split start stereotype stop title top up while
+" Since "syntax keyword" can handle only words, "top to bottom direction", "left to right direction" are excluded.
+syntax keyword plantumlKeyword across activate again allow_mixing allowmixing also alt as autonumber bold
+syntax keyword plantumlKeyword bottom box break caption center circle color create critical dashed deactivate
+syntax keyword plantumlKeyword description destroy detach dotted down else elseif empty end endif endwhile
+syntax keyword plantumlKeyword false footbox footer fork group header hide hnote if is italic kill left legend
+syntax keyword plantumlKeyword link loop mainframe map members namespace newpage normal note of on opt order
+syntax keyword plantumlKeyword over package page par partition plain ref repeat return right rnote rotate show
+syntax keyword plantumlKeyword skin skinparam split sprite start stereotype stop style then title top true up
+syntax keyword plantumlKeyword while
+
"}}}
" Not in 'java - jar plantuml.jar - language' results
syntax keyword plantumlKeyword endlegend sprite then
@@ -122,8 +126,8 @@ syntax cluster plantumlClassOp contains=plantumlClassPublic,
" Strings
syntax match plantumlSpecialString /\\n/ contained
syntax region plantumlString start=/"/ skip=/\\\\\|\\"/ end=/"/ contains=plantumlSpecialString
-syntax region plantumlString start=/'/ skip=/\\\\\|\\'/ end=/'/ contains=plantumlSpecialString
-syntax match plantumlComment /'.*$/ contains=plantumlCommentTODO
+syntax region plantumlString start=/'/ skip=/\\\\\|\\'/ end=/'/ oneline contains=plantumlSpecialString
+syntax match plantumlComment /^\s*'.*$/ contains=plantumlCommentTODO
syntax region plantumlMultilineComment start=/\/'/ end=/'\// contains=plantumlCommentTODO
syntax match plantumlTag /<\/\?[bi]>/
@@ -177,6 +181,9 @@ execute 'syntax region plantumlMindmap start=/^\([-+*]\)\1*' . s:mindmap_options
" Markdown syntax
execute 'syntax region plantumlMindmap oneline start=/^\s*\*' . s:mindmap_options . '\s/ end=/$/ contains=' . join(s:contained, ',')
+" Gantt diagram
+syntax match plantumlGanttTask /\[[^\]]\{-}\]\%('s\)\?/ contains=plantumlSpecialString
+
" Skinparam keywords
syntax case ignore
@@ -195,10 +202,10 @@ syntax keyword plantumlSkinparamKeyword ArchimateBackgroundColor ArchimateBorder
syntax keyword plantumlSkinparamKeyword ArchimateFontColor ArchimateFontName ArchimateFontSize ArchimateFontStyle
syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontColor ArchimateStereotypeFontName
syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontSize ArchimateStereotypeFontStyle ArrowColor
-syntax keyword plantumlSkinparamKeyword ArrowFontColor ArrowFontName ArrowFontSize ArrowFontStyle ArrowLollipopColor
-syntax keyword plantumlSkinparamKeyword ArrowMessageAlignment ArrowThickness ArtifactBackgroundColor ArtifactBorderColor
-syntax keyword plantumlSkinparamKeyword ArtifactFontColor ArtifactFontName ArtifactFontSize ArtifactFontStyle
-syntax keyword plantumlSkinparamKeyword ArtifactStereotypeFontColor ArtifactStereotypeFontName
+syntax keyword plantumlSkinparamKeyword ArrowFontColor ArrowFontName ArrowFontSize ArrowFontStyle ArrowHeadColor
+syntax keyword plantumlSkinparamKeyword ArrowLollipopColor ArrowMessageAlignment ArrowThickness ArtifactBackgroundColor
+syntax keyword plantumlSkinparamKeyword ArtifactBorderColor ArtifactFontColor ArtifactFontName ArtifactFontSize
+syntax keyword plantumlSkinparamKeyword ArtifactFontStyle ArtifactStereotypeFontColor ArtifactStereotypeFontName
syntax keyword plantumlSkinparamKeyword ArtifactStereotypeFontSize ArtifactStereotypeFontStyle BackgroundColor
syntax keyword plantumlSkinparamKeyword BiddableBackgroundColor BiddableBorderColor BoundaryBackgroundColor
syntax keyword plantumlSkinparamKeyword BoundaryBorderColor BoundaryFontColor BoundaryFontName BoundaryFontSize
@@ -252,42 +259,50 @@ syntax keyword plantumlSkinparamKeyword FooterFontStyle FrameBackgroundColor Fra
syntax keyword plantumlSkinparamKeyword FrameFontName FrameFontSize FrameFontStyle FrameStereotypeFontColor
syntax keyword plantumlSkinparamKeyword FrameStereotypeFontName FrameStereotypeFontSize FrameStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword GenericDisplay Guillemet Handwritten HeaderFontColor HeaderFontName
-syntax keyword plantumlSkinparamKeyword HeaderFontSize HeaderFontStyle HyperlinkColor HyperlinkUnderline
-syntax keyword plantumlSkinparamKeyword IconIEMandatoryColor IconPackageBackgroundColor IconPackageColor
-syntax keyword plantumlSkinparamKeyword IconPrivateBackgroundColor IconPrivateColor IconProtectedBackgroundColor
-syntax keyword plantumlSkinparamKeyword IconProtectedColor IconPublicBackgroundColor IconPublicColor
-syntax keyword plantumlSkinparamKeyword InterfaceBackgroundColor InterfaceBorderColor InterfaceFontColor
+syntax keyword plantumlSkinparamKeyword HeaderFontSize HeaderFontStyle HexagonBackgroundColor HexagonBorderColor
+syntax keyword plantumlSkinparamKeyword HexagonBorderThickness HexagonFontColor HexagonFontName HexagonFontSize
+syntax keyword plantumlSkinparamKeyword HexagonFontStyle HexagonStereotypeFontColor HexagonStereotypeFontName
+syntax keyword plantumlSkinparamKeyword HexagonStereotypeFontSize HexagonStereotypeFontStyle HyperlinkColor
+syntax keyword plantumlSkinparamKeyword HyperlinkUnderline IconIEMandatoryColor IconPackageBackgroundColor
+syntax keyword plantumlSkinparamKeyword IconPackageColor IconPrivateBackgroundColor IconPrivateColor
+syntax keyword plantumlSkinparamKeyword IconProtectedBackgroundColor IconProtectedColor IconPublicBackgroundColor
+syntax keyword plantumlSkinparamKeyword IconPublicColor InterfaceBackgroundColor InterfaceBorderColor InterfaceFontColor
syntax keyword plantumlSkinparamKeyword InterfaceFontName InterfaceFontSize InterfaceFontStyle
syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontColor InterfaceStereotypeFontName
-syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontSize InterfaceStereotypeFontStyle LegendBackgroundColor
-syntax keyword plantumlSkinparamKeyword LegendBorderColor LegendBorderThickness LegendFontColor LegendFontName
-syntax keyword plantumlSkinparamKeyword LegendFontSize LegendFontStyle LexicalBackgroundColor LexicalBorderColor
-syntax keyword plantumlSkinparamKeyword LifelineStrategy Linetype MachineBackgroundColor MachineBorderColor
-syntax keyword plantumlSkinparamKeyword LineColor LineStyle LineThickness
-syntax keyword plantumlSkinparamKeyword MachineBorderThickness MachineFontColor MachineFontName MachineFontSize
-syntax keyword plantumlSkinparamKeyword MachineFontStyle MachineStereotypeFontColor MachineStereotypeFontName
-syntax keyword plantumlSkinparamKeyword MachineStereotypeFontSize MachineStereotypeFontStyle MaxAsciiMessageLength
-syntax keyword plantumlSkinparamKeyword MaxMessageSize MinClassWidth Monochrome NodeBackgroundColor NodeBorderColor
-syntax keyword plantumlSkinparamKeyword NodeFontColor NodeFontName NodeFontSize NodeFontStyle NodeStereotypeFontColor
-syntax keyword plantumlSkinparamKeyword NodeStereotypeFontName NodeStereotypeFontSize NodeStereotypeFontStyle Nodesep
-syntax keyword plantumlSkinparamKeyword NoteBackgroundColor NoteBorderColor NoteBorderThickness NoteFontColor
-syntax keyword plantumlSkinparamKeyword NoteFontName NoteFontSize NoteFontStyle NoteShadowing NoteTextAlignment
-syntax keyword plantumlSkinparamKeyword ObjectAttributeFontColor ObjectAttributeFontName ObjectAttributeFontSize
-syntax keyword plantumlSkinparamKeyword ObjectAttributeFontStyle ObjectBackgroundColor ObjectBorderColor
-syntax keyword plantumlSkinparamKeyword ObjectBorderThickness ObjectFontColor ObjectFontName ObjectFontSize
-syntax keyword plantumlSkinparamKeyword ObjectFontStyle ObjectStereotypeFontColor ObjectStereotypeFontName
-syntax keyword plantumlSkinparamKeyword ObjectStereotypeFontSize ObjectStereotypeFontStyle PackageBackgroundColor
-syntax keyword plantumlSkinparamKeyword PackageBorderColor PackageBorderThickness PackageFontColor PackageFontName
-syntax keyword plantumlSkinparamKeyword PackageFontSize PackageFontStyle PackageStereotypeFontColor
-syntax keyword plantumlSkinparamKeyword PackageStereotypeFontName PackageStereotypeFontSize PackageStereotypeFontStyle
-syntax keyword plantumlSkinparamKeyword PackageStyle PackageTitleAlignment Padding PageBorderColor PageExternalColor
-syntax keyword plantumlSkinparamKeyword PageMargin ParticipantBackgroundColor ParticipantBorderColor
-syntax keyword plantumlSkinparamKeyword ParticipantFontColor ParticipantFontName ParticipantFontSize
-syntax keyword plantumlSkinparamKeyword ParticipantFontStyle ParticipantPadding ParticipantStereotypeFontColor
-syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontName ParticipantStereotypeFontSize
-syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontStyle PartitionBackgroundColor PartitionBorderColor
-syntax keyword plantumlSkinparamKeyword PartitionBorderThickness PartitionFontColor PartitionFontName PartitionFontSize
-syntax keyword plantumlSkinparamKeyword PartitionFontStyle PathHoverColor QueueBackgroundColor QueueBorderColor
+syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontSize InterfaceStereotypeFontStyle LabelFontColor
+syntax keyword plantumlSkinparamKeyword LabelFontName LabelFontSize LabelFontStyle LabelStereotypeFontColor
+syntax keyword plantumlSkinparamKeyword LabelStereotypeFontName LabelStereotypeFontSize LabelStereotypeFontStyle
+syntax keyword plantumlSkinparamKeyword LegendBackgroundColor LegendBorderColor LegendBorderThickness LegendFontColor
+syntax keyword plantumlSkinparamKeyword LegendFontName LegendFontSize LegendFontStyle LexicalBackgroundColor
+syntax keyword plantumlSkinparamKeyword LexicalBorderColor LifelineStrategy Linetype MachineBackgroundColor
+syntax keyword plantumlSkinparamKeyword MachineBorderColor MachineBorderThickness MachineFontColor MachineFontName
+syntax keyword plantumlSkinparamKeyword MachineFontSize MachineFontStyle MachineStereotypeFontColor
+syntax keyword plantumlSkinparamKeyword MachineStereotypeFontName MachineStereotypeFontSize MachineStereotypeFontStyle
+syntax keyword plantumlSkinparamKeyword MaxAsciiMessageLength MaxMessageSize MinClassWidth Monochrome
+syntax keyword plantumlSkinparamKeyword NodeBackgroundColor NodeBorderColor NodeFontColor NodeFontName NodeFontSize
+syntax keyword plantumlSkinparamKeyword NodeFontStyle NodeStereotypeFontColor NodeStereotypeFontName
+syntax keyword plantumlSkinparamKeyword NodeStereotypeFontSize NodeStereotypeFontStyle Nodesep NoteBackgroundColor
+syntax keyword plantumlSkinparamKeyword NoteBorderColor NoteBorderThickness NoteFontColor NoteFontName NoteFontSize
+syntax keyword plantumlSkinparamKeyword NoteFontStyle NoteShadowing NoteTextAlignment ObjectAttributeFontColor
+syntax keyword plantumlSkinparamKeyword ObjectAttributeFontName ObjectAttributeFontSize ObjectAttributeFontStyle
+syntax keyword plantumlSkinparamKeyword ObjectBackgroundColor ObjectBorderColor ObjectBorderThickness ObjectFontColor
+syntax keyword plantumlSkinparamKeyword ObjectFontName ObjectFontSize ObjectFontStyle ObjectStereotypeFontColor
+syntax keyword plantumlSkinparamKeyword ObjectStereotypeFontName ObjectStereotypeFontSize ObjectStereotypeFontStyle
+syntax keyword plantumlSkinparamKeyword PackageBackgroundColor PackageBorderColor PackageBorderThickness
+syntax keyword plantumlSkinparamKeyword PackageFontColor PackageFontName PackageFontSize PackageFontStyle
+syntax keyword plantumlSkinparamKeyword PackageStereotypeFontColor PackageStereotypeFontName PackageStereotypeFontSize
+syntax keyword plantumlSkinparamKeyword PackageStereotypeFontStyle PackageStyle PackageTitleAlignment Padding
+syntax keyword plantumlSkinparamKeyword PageBorderColor PageExternalColor PageMargin ParticipantBackgroundColor
+syntax keyword plantumlSkinparamKeyword ParticipantBorderColor ParticipantFontColor ParticipantFontName
+syntax keyword plantumlSkinparamKeyword ParticipantFontSize ParticipantFontStyle ParticipantPadding
+syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontColor ParticipantStereotypeFontName
+syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontSize ParticipantStereotypeFontStyle
+syntax keyword plantumlSkinparamKeyword PartitionBackgroundColor PartitionBorderColor PartitionBorderThickness
+syntax keyword plantumlSkinparamKeyword PartitionFontColor PartitionFontName PartitionFontSize PartitionFontStyle
+syntax keyword plantumlSkinparamKeyword PathHoverColor PersonBackgroundColor PersonBorderColor PersonBorderThickness
+syntax keyword plantumlSkinparamKeyword PersonFontColor PersonFontName PersonFontSize PersonFontStyle
+syntax keyword plantumlSkinparamKeyword PersonStereotypeFontColor PersonStereotypeFontName PersonStereotypeFontSize
+syntax keyword plantumlSkinparamKeyword PersonStereotypeFontStyle QueueBackgroundColor QueueBorderColor
syntax keyword plantumlSkinparamKeyword QueueBorderThickness QueueFontColor QueueFontName QueueFontSize QueueFontStyle
syntax keyword plantumlSkinparamKeyword QueueStereotypeFontColor QueueStereotypeFontName QueueStereotypeFontSize
syntax keyword plantumlSkinparamKeyword QueueStereotypeFontStyle Ranksep RectangleBackgroundColor RectangleBorderColor
@@ -343,6 +358,7 @@ syntax keyword plantumlSkinparamKeyword UsecaseBackgroundColor UsecaseBorderColo
syntax keyword plantumlSkinparamKeyword UsecaseFontColor UsecaseFontName UsecaseFontSize UsecaseFontStyle
syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontColor UsecaseStereotypeFontName UsecaseStereotypeFontSize
syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontStyle WrapWidth
+
" Not in 'java - jar plantuml.jar - language' output
syntax keyword plantumlSkinparamKeyword activityArrowColor activityArrowFontColor activityArrowFontName
syntax keyword plantumlSkinparamKeyword activityArrowFontSize activityArrowFontStyle BarColor BorderColor
@@ -357,6 +373,7 @@ syntax keyword plantumlSkinparamKeyword FontSize FontStyle GroupBackgroundColor
syntax keyword plantumlSkinparamKeyword GroupingFontSize GroupingFontStyle GroupingHeaderFontColor
syntax keyword plantumlSkinparamKeyword GroupingHeaderFontName GroupingHeaderFontSize GroupingHeaderFontStyle
syntax keyword plantumlSkinparamKeyword LifeLineBackgroundColor LifeLineBorderColor
+syntax keyword plantumlSkinparamKeyword LineColor LineStyle LineThickness
syntax keyword plantumlSkinparamKeyword sequenceActorBackgroundColor sequenceActorBorderColor sequenceActorFontColor
syntax keyword plantumlSkinparamKeyword sequenceActorFontName sequenceActorFontSize sequenceActorFontStyle
syntax keyword plantumlSkinparamKeyword sequenceArrowColor sequenceArrowFontColor sequenceArrowFontName
@@ -377,6 +394,10 @@ syntax keyword plantumlSkinparamKeyword usecaseActorStereotypeFontStyle usecaseA
syntax keyword plantumlSkinparamKeyword usecaseArrowFontName usecaseArrowFontSize usecaseArrowFontStyle
syntax case match
+" Builtin Function
+" https://plantuml.com/ja/preprocessing
+syntax match plantumlBuiltinFunction /%\%(chr\|darken\|date\|dec2hex\|dirpath\|feature\|false\|file_exists\|filename\|function_exists\|get_variable_value\|getenv\|hex2dec\|hsl_color\|intval\|is_dark\|is_light\|lighten\|loadJSON\|lower\|newline\|not\|lighten\|reverse_color\|reverse_hsluv_color\|set_variable_value\|size\|string\|strlen\|strpos\|substr\|true\|upper\|variable_exists\|version\)/
+
" Highlight
highlight default link plantumlCommentTODO Todo
highlight default link plantumlKeyword Keyword
@@ -415,6 +436,8 @@ highlight default link plantumlSkinparamKeyword Identifier
highlight default link plantumlNoteMultiLine String
highlight default link plantumlUsecaseActor String
highlight default link plantumlStereotype Type
+highlight default link plantumlBuiltinFunction Function
+highlight default link plantumlGanttTask Type
let &cpoptions=s:cpo_orig
unlet s:cpo_orig
diff --git a/syntax/rc.vim b/syntax/rc.vim
index 7d85d60a..ab14a43f 100644
--- a/syntax/rc.vim
+++ b/syntax/rc.vim
@@ -5,7 +5,7 @@ endif
" Vim syntax file
" Language: M$ Resource files (*.rc)
" Maintainer: Christian Brabandt
-" Last Change: 2015-05-29
+" Last Change: 20220116
" Repository: https://github.com/chrisbra/vim-rc-syntax
" License: Vim (see :h license)
" Previous Maintainer: Heiko Erhardt <Heiko.Erhardt@munich.netsurf.de>
@@ -177,16 +177,17 @@ hi def link rcAttribute rcCommonAttribute
hi def link rcStdId rcStatement
hi def link rcStatement Statement
-" Default color overrides
-hi def rcLanguage term=reverse ctermbg=Red ctermfg=Yellow guibg=Red guifg=Yellow
-hi def rcMainObject term=underline ctermfg=Blue guifg=Blue
-hi def rcSubObject ctermfg=Green guifg=Green
-hi def rcCaptionParam term=underline ctermfg=DarkGreen guifg=Green
-hi def rcParam ctermfg=DarkGreen guifg=DarkGreen
-hi def rcStatement ctermfg=DarkGreen guifg=DarkGreen
-hi def rcCommonAttribute ctermfg=Brown guifg=Brown
+hi def link rcLanguage Constant
+hi def link rcCaptionParam Constant
+hi def link rcCommonAttribute Constant
+
+hi def link rcMainObject Identifier
+hi def link rcSubObject Define
+hi def link rcParam Constant
+hi def link rcStatement Statement
+"
+"hi def link rcIdentifier Identifier
-"hi def link rcIdentifier Identifier
let b:current_syntax = "rc"
diff --git a/syntax/swift.vim b/syntax/swift.vim
index 8b41f560..6ea8a81f 100644
--- a/syntax/swift.vim
+++ b/syntax/swift.vim
@@ -215,6 +215,7 @@ syntax keyword swiftAttributes
\ @NSCopying
\ @NSManaged
\ @objc
+ \ @preconcurrency
\ @propertyWrapper
\ @resultBuilder
\ @Sendable
@@ -223,7 +224,9 @@ syntax keyword swiftAttributes
\ @usableFromInline
\ @warn_unused_result
-syntax keyword swiftConditionStatement #available
+syntax keyword swiftConditionStatement
+ \ #available
+ \ #unavailable
syntax keyword swiftStructure
\ struct
diff --git a/syntax/tmux.vim b/syntax/tmux.vim
index 4505f10e..69fdd611 100644
--- a/syntax/tmux.vim
+++ b/syntax/tmux.vim
@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'tmux', 'syntax/tmux.vim')
endif
" Language: tmux(1) configuration file
-" Version: 3.3-rc (git-77fc7ac3)
+" Version: 3.3-rc (git-85ef7359)
" URL: https://github.com/ericpruitt/tmux.vim/
" Maintainer: Eric Pruitt <eric.pruitt@gmail.com>
" License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause)
@@ -78,23 +78,24 @@ syn keyword tmuxOptions
\ display-panes-active-colour display-panes-colour display-panes-time
\ display-time exit-empty exit-unattached extended-keys focus-events
\ history-file history-limit key-table lock-after-time lock-command
-\ message-command-style message-limit aggressive-resize allow-rename
-\ alternate-screen automatic-rename automatic-rename-format
+\ message-command-style message-limit aggressive-resize allow-passthrough
+\ allow-rename alternate-screen automatic-rename automatic-rename-format
\ clock-mode-colour clock-mode-style copy-mode-current-match-style
\ copy-mode-mark-style copy-mode-match-style main-pane-height
\ main-pane-width message-style mode-keys mode-style monitor-activity
\ monitor-bell monitor-silence mouse other-pane-height other-pane-width
\ pane-active-border-style pane-base-index pane-border-format
-\ pane-border-lines pane-border-status pane-border-style pane-colours
-\ popup-border-lines popup-border-style popup-style prefix prefix2
-\ prompt-history-limit remain-on-exit renumber-windows repeat-time
-\ set-clipboard set-titles set-titles-string silence-action status status-bg
-\ status-fg status-format status-interval status-justify status-keys
-\ status-left status-left-length status-left-style status-position
-\ status-right status-right-length status-right-style status-style
-\ synchronize-panes terminal-features terminal-overrides update-environment
-\ user-keys visual-activity visual-bell visual-silence window-active-style
-\ window-size window-status-activity-style window-status-bell-style
+\ pane-border-indicators pane-border-lines pane-border-status
+\ pane-border-style pane-colours popup-border-lines popup-border-style
+\ popup-style prefix prefix2 prompt-history-limit remain-on-exit
+\ renumber-windows repeat-time set-clipboard set-titles set-titles-string
+\ silence-action status status-bg status-fg status-format status-interval
+\ status-justify status-keys status-left status-left-length
+\ status-left-style status-position status-right status-right-length
+\ status-right-style status-style synchronize-panes terminal-features
+\ terminal-overrides update-environment user-keys visual-activity
+\ visual-bell visual-silence window-active-style window-size
+\ window-status-activity-style window-status-bell-style
\ window-status-current-format window-status-current-style
\ window-status-format window-status-last-style window-status-separator
\ window-status-style window-style word-separators wrap-search
diff --git a/syntax/zig.vim b/syntax/zig.vim
index b3ad6fb2..287ce0ba 100644
--- a/syntax/zig.vim
+++ b/syntax/zig.vim
@@ -22,6 +22,7 @@ let s:zig_syntax_keywords = {
\ , "f16"
\ , "f32"
\ , "f64"
+ \ , "f80"
\ , "f128"
\ , "void"
\ , "type"
@@ -146,6 +147,7 @@ let s:zig_syntax_keywords = {
\ , "@offsetOf"
\ , "@OpaqueType"
\ , "@panic"
+ \ , "@prefetch"
\ , "@ptrCast"
\ , "@ptrToInt"
\ , "@rem"
@@ -154,6 +156,7 @@ let s:zig_syntax_keywords = {
\ , "@Type"
\ , "@shuffle"
\ , "@reduce"
+ \ , "@select"
\ , "@setRuntimeSafety"
\ , "@setEvalBranchQuota"
\ , "@setFloatMode"