summaryrefslogtreecommitdiffstats
path: root/syntax/pgsql.vim
diff options
context:
space:
mode:
Diffstat (limited to 'syntax/pgsql.vim')
-rw-r--r--syntax/pgsql.vim16
1 files changed, 11 insertions, 5 deletions
diff --git a/syntax/pgsql.vim b/syntax/pgsql.vim
index 81acfd2b..70c3d38c 100644
--- a/syntax/pgsql.vim
+++ b/syntax/pgsql.vim
@@ -9,7 +9,7 @@ endif
" License: Vim license (see `:help license`)
" Based on PostgreSQL 13.1
-" Automatically generated on 2020-12-30 at 10:21:40
+" Automatically generated on 2021-01-13 at 20:54:21
if exists("b:current_syntax")
finish
@@ -2010,20 +2010,26 @@ else
\ contains=sqlIsKeyword,sqlIsFunction,sqlComment,sqlPlpgsqlKeyword,sqlPlpgsqlVariable,sqlPlpgsqlOperator,sqlNumber,sqlIsOperator,sqlString,sqlTodo
endif
-" Folding
-syn region sqlFold start='^\s*\zs\c\(create\|update\|alter\|select\|insert\|do\)\>' end=';$' transparent fold contains=sqlIsKeyword,sqlIsFunction,sqlComment,sqlIdentifier,sqlNumber,sqlOperator,sqlSpecial,sqlString,sqlTodo,plpgsql
+let s:plgroups = 'plpgsql'
" PL/<any other language>
fun! s:add_syntax(s)
- execute 'syn include @PL' . a:s . ' syntax/' . a:s . '.vim'
+ execute 'syn include @PL' .. a:s .. ' syntax/' .. a:s .. '.vim'
unlet b:current_syntax
- execute 'syn region pgsqlpl' . a:s . ' matchgroup=sqlString start=+\$' . a:s . '\$+ end=+\$' . a:s . '\$+ keepend contains=@PL' . a:s
+ execute 'syn region pgsqlpl' .. a:s .. ' matchgroup=sqlString start=+\$' .. a:s .. '\$+ end=+\$' .. a:s .. '\$+ keepend contains=@PL' .. a:s
+ let s:plgroups .= ',pgsqlpl' .. a:s
endf
for pl in get(b:, 'pgsql_pl', get(g:, 'pgsql_pl', []))
call s:add_syntax(pl)
endfor
+" Folding
+execute "syn region sqlFold start='^\s*\zs\c\(create\|update\|alter\|select\|insert\|do\)\>' end=';$' transparent fold "
+ \ .. "contains=sqlIsKeyword,sqlIsFunction,sqlComment,sqlIdentifier,sqlNumber,sqlOperator,sqlSpecial,sqlString,sqlTodo," .. s:plgroups
+
+unlet s:plgroups
+
" Default highlighting
hi def link sqlCatalog Constant
hi def link sqlComment Comment