Skip to content

Commit 7ade8c3

Browse files
committed
Use 'cargo rustc -Zno-trans' for syntastic checker
1 parent 9924277 commit 7ade8c3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

syntax_checkers/rust/rustc.vim

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ let s:save_cpo = &cpo
1414
set cpo&vim
1515

1616
function! SyntaxCheckers_rust_rustc_GetLocList() dict
17-
let makeprg = self.makeprgBuild({ 'args': '-Zparse-only' })
17+
let makeprg = self.makeprgBuild({
18+
\ 'args': 'rustc -Zno-trans',
19+
\ 'fname': '' })
1820

1921
let errorformat =
2022
\ '%E%f:%l:%c: %\d%#:%\d%# %.%\{-}error:%.%\{-} %m,' .
@@ -28,6 +30,7 @@ function! SyntaxCheckers_rust_rustc_GetLocList() dict
2830
endfunction
2931

3032
call g:SyntasticRegistry.CreateAndRegisterChecker({
33+
\ 'exec': 'cargo',
3134
\ 'filetype': 'rust',
3235
\ 'name': 'rustc'})
3336

0 commit comments

Comments
 (0)