Skip to content

Commit b4868c7

Browse files
committed
Add comments for some extensions + test
1 parent d221139 commit b4868c7

File tree

10 files changed

+185
-188
lines changed

10 files changed

+185
-188
lines changed

after/syntax/c.vim

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'cpp-modern') ==
77
" http://www.vim.org/scripts/script.php?script_id=3064
88
" Maintainer: bfrg <bfrg@users.noreply.github.com>
99
" Website: https://github.com/bfrg/vim-cpp-modern
10-
" Last Change: Mar 14, 2020
10+
" Last Change: Oct 4, 2020
1111
"
1212
" Extended C syntax highlighting including highlighting of user-defined
1313
" functions.
@@ -17,7 +17,7 @@ if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'cpp-modern') ==
1717
" ==============================================================================
1818

1919

20-
" Highlight some additional keywords in the comments
20+
" Highlight additional keywords in the comments
2121
syn keyword cTodo contained BUG NOTE
2222

2323

@@ -50,25 +50,4 @@ if get(g:, 'cpp_simple_highlight', 0)
5050
hi link cLabel Statement
5151
endif
5252

53-
54-
" Operators
55-
" syn match cOperator "\(<<\|>>\|[-+*/%&^|<>!=]\)="
56-
" syn match cOperator "<<\|>>\|&&\|||\|++\|--\|->"
57-
" syn match cOperator "[.!~*&%<>^|=,+-]"
58-
" syn match cOperator "/[^/*=]"me=e-1
59-
" syn match cOperator "/$"
60-
" syn match cOperator "&&\|||"
61-
" syn match cOperator "[][]"
62-
63-
" Preprocessor
64-
" syn keyword cDefined defined contained containedin=cDefine
65-
" hi def link cDefined cDefine
66-
67-
" Delimiters
68-
" syn match cDelimiter "[();\\]"
69-
" hi def link cDelimiter Delimiter
70-
" foldmethod=syntax fix, courtesy of Ivan Freitas
71-
" syn match cBraces display "[{}]"
72-
" hi def link cBraces Delimiter
73-
7453
endif

after/syntax/cpp.vim

Lines changed: 39 additions & 20 deletions
Large diffs are not rendered by default.

after/syntax/javascript/graphql.vim

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ let s:tags = '\%(' . join(graphql#javascript_tags(), '\|') . '\)'
3636

3737
if graphql#has_syntax_group('jsTemplateExpression')
3838
" pangloss/vim-javascript
39-
exec 'syntax region graphqlTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend'
39+
exec 'syntax region graphqlTemplateString matchgroup=jsTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend'
4040
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
4141
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=jsTemplateExpression containedin=graphqlFold keepend
4242

@@ -48,7 +48,7 @@ if graphql#has_syntax_group('jsTemplateExpression')
4848
syn cluster graphqlTaggedTemplate add=graphqlTemplateString
4949
elseif graphql#has_syntax_group('javaScriptStringT')
5050
" runtime/syntax/javascript.vim
51-
exec 'syntax region graphqlTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend'
51+
exec 'syntax region graphqlTemplateString matchgroup=javaScriptStringT start=+' . s:tags . '\@20<=`+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend'
5252
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
5353
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=@javaScriptEmbededExpr containedin=graphqlFold keepend
5454

after/syntax/typescript/graphql.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ endif
3434

3535
let s:tags = '\%(' . join(graphql#javascript_tags(), '\|') . '\)'
3636

37-
exec 'syntax region graphqlTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\`+ end=+`+ contains=@GraphQLSyntax,typescriptTemplateSubstitution extend'
37+
exec 'syntax region graphqlTemplateString matchgroup=typescriptTemplate start=+' . s:tags . '\@20<=`+ skip=+\\`+ end=+`+ contains=@GraphQLSyntax,typescriptTemplateSubstitution extend'
3838
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
3939

4040
" Support expression interpolation ((${...})) inside template strings.

doc/pgsql.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ Text enclosed between `$anyword$` pairs, where `anyword` is any non-empty
5353
sequence of word characters different from those with a special meaning (such
5454
as `$pgsql$`) is treated as a multi-line string.
5555

56+
When |foldmethod| is set to "syntax", SQL commands can be folded.
57+
5658
Finally, the plugin supports syntax highlighting of arbitrary languages within
5759
procedure and function blocks. This feature needs to be configured: see
5860
|g:pgsql_pl|.

0 commit comments

Comments
 (0)