BaseX checker: cleanup.
This commit is contained in:
parent
3c524a661c
commit
50653f0bc6
@ -62,8 +62,8 @@ Mercury, NASM, Nix, Objective-C, Objective-C++, OCaml, Perl, Perl POD, PHP,
|
|||||||
gettext Portable Object, OS X and iOS property lists, Puppet, Python, QML, R,
|
gettext Portable Object, OS X and iOS property lists, Puppet, Python, QML, R,
|
||||||
Racket, Relax NG, reStructuredText, RPM spec, Ruby, SASS/SCSS, Scala, Slim,
|
Racket, Relax NG, reStructuredText, RPM spec, Ruby, SASS/SCSS, Scala, Slim,
|
||||||
SML, Sphinx, SQL, Stylus, Tcl, TeX, Texinfo, Twig, TypeScript, Vala, Verilog,
|
SML, Sphinx, SQL, Stylus, Tcl, TeX, Texinfo, Twig, TypeScript, Vala, Verilog,
|
||||||
VHDL, VimL, xHtml, XML, XSLT, YACC, YAML, z80, Zope page templates, and zsh.
|
VHDL, VimL, xHtml, XML, XSLT, XQuery, YACC, YAML, z80, Zope page templates, and
|
||||||
See the [wiki][3] for details about the corresponding supported checkers.
|
zsh. See the [wiki][3] for details about the corresponding supported checkers.
|
||||||
|
|
||||||
A number of third-party Vim plugins also provide checkers for syntastic,
|
A number of third-party Vim plugins also provide checkers for syntastic,
|
||||||
for example: [merlin][30], [omnisharp-vim][25], [rust.vim][12],
|
for example: [merlin][30], [omnisharp-vim][25], [rust.vim][12],
|
||||||
|
@ -19,7 +19,7 @@ if has('reltime')
|
|||||||
lockvar! g:_SYNTASTIC_START
|
lockvar! g:_SYNTASTIC_START
|
||||||
endif
|
endif
|
||||||
|
|
||||||
let g:_SYNTASTIC_VERSION = '3.7.0-6'
|
let g:_SYNTASTIC_VERSION = '3.7.0-9'
|
||||||
lockvar g:_SYNTASTIC_VERSION
|
lockvar g:_SYNTASTIC_VERSION
|
||||||
|
|
||||||
" Sanity checks {{{1
|
" Sanity checks {{{1
|
||||||
|
@ -17,27 +17,28 @@ let g:loaded_syntastic_xquery_basex_checker = 1
|
|||||||
let s:save_cpo = &cpo
|
let s:save_cpo = &cpo
|
||||||
set cpo&vim
|
set cpo&vim
|
||||||
|
|
||||||
if exists('g:syntastic_extra_filetypes')
|
function! SyntaxCheckers_xquery_basex_GetLocList() dict
|
||||||
call add(g:syntastic_extra_filetypes, 'xquery')
|
let makeprg = self.makeprgBuild({
|
||||||
else
|
\ 'fname_before': '-z',
|
||||||
let g:syntastic_extra_filetypes = ['xquery']
|
\ 'fname': ['-q', "inspect:module('" . expand('%:p', 1) . "')"] })
|
||||||
endif
|
|
||||||
|
|
||||||
function SyntaxCheckers_xquery_basex_IsAvailable() dict
|
|
||||||
return executable(expand(self.getExec(), 1))
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
function SyntaxCheckers_xquery_basex_GetLocList() dict
|
|
||||||
let makeprg = 'basex -z -q "inspect:module(' . "'" . expand("%:p") . "')" . '"'
|
|
||||||
let errorformat =
|
let errorformat =
|
||||||
\ '%-GStopped at .\, %l/%c:,'.
|
\ '%-GStopped at %\%.\, %l/%c:,'.
|
||||||
\ '%E[%.%#] Stopped at %f\, %l/%c:,'.
|
\ '%A[%.%#] Stopped at %f\, %l/%c:,'.
|
||||||
\ '%Z[%t%#%n] %m'
|
\ '%Z[%t%\D%#%n] %m'
|
||||||
|
|
||||||
return SyntasticMake({
|
let loclist = SyntasticMake({
|
||||||
\ 'makeprg': makeprg,
|
\ 'makeprg': makeprg,
|
||||||
\ 'errorformat': errorformat
|
\ 'errorformat': errorformat,
|
||||||
\ })
|
\ 'postprocess': ['compressWhitespace'] })
|
||||||
|
|
||||||
|
for e in loclist
|
||||||
|
if e['type'] !=# 'W' && e['type'] !=# 'E'
|
||||||
|
let e['type'] = 'E'
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
|
||||||
|
return loclist
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
call g:SyntasticRegistry.CreateAndRegisterChecker({
|
call g:SyntasticRegistry.CreateAndRegisterChecker({
|
||||||
|
Loading…
Reference in New Issue
Block a user