aboutsummaryrefslogtreecommitdiff
path: root/runtime/syntax/cabal.vim
diff options
context:
space:
mode:
authorSean Dewar <seandewar@users.noreply.github.com>2022-11-10 09:05:25 +0000
committerGitHub <noreply@github.com>2022-11-10 09:05:25 +0000
commitbefae73044fa367c6d0d82bf4b61501010e7545d (patch)
tree0ac3389893595903df770553daea260e9ce18f47 /runtime/syntax/cabal.vim
parent61d152779d9e84b52fc85d24cea51ad04284054d (diff)
downloadrneovim-befae73044fa367c6d0d82bf4b61501010e7545d.tar.gz
rneovim-befae73044fa367c6d0d82bf4b61501010e7545d.tar.bz2
rneovim-befae73044fa367c6d0d82bf4b61501010e7545d.zip
vim-patch:76db9e076318 (#21013)
Update runtime files https://github.com/vim/vim/commit/76db9e076318cb0ae846f43b7549ad4f2d234c0b - `col()`'s example was changed to use `:echowin` so that the message can be seen with `showmode`. Use "\n" to force a hit-enter instead as `:echowin` isn't ported. - Replace interpolated string usage in syntax/modula3.vim (not ported). - Add a space after the `wincmd =` examples in `*CTRL-W_=*` so that the inlined code is highlighted properly when followed by a full stop. Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'runtime/syntax/cabal.vim')
-rw-r--r--runtime/syntax/cabal.vim21
1 files changed, 18 insertions, 3 deletions
diff --git a/runtime/syntax/cabal.vim b/runtime/syntax/cabal.vim
index 92e6b8331e..74cda51266 100644
--- a/runtime/syntax/cabal.vim
+++ b/runtime/syntax/cabal.vim
@@ -4,7 +4,9 @@
" Maintainer: Marcin Szamotulski <profunctor@pm.me>
" Previous Maintainer: Vincent Berthoux <twinside@gmail.com>
" File Types: .cabal
-" Last Change: 21 Nov 2020
+" Last Change: 22 Oct 2022
+" v1.6: Added support for foreign-libraries
+" Added highlighting for various fields
" v1.5: Incorporated changes from
" https://github.com/sdiehl/haskell-vim-proto/blob/master/vim/syntax/cabal.vim
" Use `syn keyword` instead of `syn match`.
@@ -61,13 +63,14 @@ syn keyword cabalCategory contained
\ test-suite
\ source-repository
\ flag
+ \ foreign-library
\ custom-setup
\ common
syn match cabalCategoryTitle contained /[^{]*\ze{\?/
syn match cabalCategoryRegion
\ contains=cabalCategory,cabalCategoryTitle
\ nextgroup=cabalCategory skipwhite
- \ /^\c\s*\(contained\|executable\|library\|benchmark\|test-suite\|source-repository\|flag\|custom-setup\|common\)\+\s*\%(.*$\|$\)/
+ \ /^\c\s*\(contained\|executable\|library\|benchmark\|test-suite\|source-repository\|flag\|foreign-library\|custom-setup\|common\)\+\s*\%(.*$\|$\)/
syn keyword cabalTruth true false
" cabalStatementRegion which limits the scope of cabalStatement keywords, this
@@ -77,6 +80,7 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ default-language
\ default-extensions
\ author
+ \ autogen-includes
\ autogen-modules
\ asm-sources
\ asm-options
@@ -84,7 +88,7 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ bug-reports
\ build-depends
\ build-tools
- \ build-tools-depends
+ \ build-tool-depends
\ build-type
\ buildable
\ c-sources
@@ -95,6 +99,7 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ cmm-sources
\ cmm-options
\ cpp-options
+ \ cxx-options
\ cxx-sources
\ data-dir
\ data-files
@@ -111,7 +116,9 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ extra-framework-dirs
\ extra-ghci-libraries
\ extra-lib-dirs
+ \ extra-lib-dirs-static
\ extra-libraries
+ \ extra-libraries-static
\ extra-library-flavours
\ extra-source-files
\ extra-tmp-files
@@ -133,6 +140,8 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ install-includes
\ js-sources
\ ld-options
+ \ lib-version-info
+ \ lib-version-linux
\ license
\ license-file
\ location
@@ -141,20 +150,26 @@ syn keyword cabalStatement contained containedin=cabalStatementRegion
\ manual
\ mixins
\ module
+ \ mod-def-file
\ name
\ nhc98-options
+ \ options
\ other-extensions
\ other-language
\ other-languages
\ other-modules
\ package-url
\ pkgconfig-depends
+ \ scope
\ setup-depends
+ \ signatures
\ stability
\ subdir
\ synopsis
+ \ reexported-modules
\ tag
\ tested-with
+ \ test-module
\ type
\ version
\ virtual-modules