Checker go/gotype: option "-a" is now "-t".
This commit is contained in:
parent
e07319fd45
commit
fc7d4cea42
@ -19,7 +19,7 @@ if has('reltime')
|
||||
lockvar! g:_SYNTASTIC_START
|
||||
endif
|
||||
|
||||
let g:_SYNTASTIC_VERSION = '3.8.0-52'
|
||||
let g:_SYNTASTIC_VERSION = '3.8.0-53'
|
||||
lockvar g:_SYNTASTIC_VERSION
|
||||
|
||||
" Sanity checks {{{1
|
||||
|
@ -20,8 +20,24 @@ set cpo&vim
|
||||
|
||||
function! SyntaxCheckers_go_gotype_GetLocList() dict
|
||||
let buf = bufnr('')
|
||||
|
||||
if !exists('s:go_new')
|
||||
let command = syntastic#util#shescape(syntastic#util#bufVar(buf, 'go_go_exec', 'go')) . ' version'
|
||||
let version_output = syntastic#util#system(command)
|
||||
call self.log('finding go version: ' . string(command) . ': ' .
|
||||
\ string(split(version_output, "\n", 1)) .
|
||||
\ (v:shell_error ? ' (exit code ' . v:shell_error . ')' : ''))
|
||||
let parsed_ver = syntastic#util#parseVersion(version_output)
|
||||
if len(parsed_ver)
|
||||
let s:go_new = syntastic#util#versionIsAtLeast(parsed_ver, [1, 8])
|
||||
else
|
||||
call syntastic#log#error("checker " . self.getCName() . ": can't parse go version (abnormal termination?)")
|
||||
return []
|
||||
endif
|
||||
endif
|
||||
|
||||
let makeprg = self.makeprgBuild({
|
||||
\ 'args': (bufname(buf) =~# '\m_test\.go$' ? '-a' : ''),
|
||||
\ 'args': (bufname(buf) =~# '\m_test\.go$' ? (s:go_new ? '-t' : '-a') : ''),
|
||||
\ 'fname': '.' })
|
||||
|
||||
let errorformat =
|
||||
|
Loading…
Reference in New Issue
Block a user