From 7bd9b98342c93b7c7b06ddea19949233190106ce Mon Sep 17 00:00:00 2001 From: Daniel Trstenjak Date: Sat, 5 Apr 2014 15:47:20 +0200 Subject: [PATCH] Always give absolute paths to syntax checkers 'hdevtools' and 'hlint' Especially for 'hdevtools' this results into a more robust behaviour, because 'hdevtools' starts a background process and changing the current directory doesn't affect the current directory of the background process. --- syntax_checkers/haskell/hdevtools.vim | 1 + syntax_checkers/haskell/hlint.vim | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/syntax_checkers/haskell/hdevtools.vim b/syntax_checkers/haskell/hdevtools.vim index 29abca7e..7dde6381 100644 --- a/syntax_checkers/haskell/hdevtools.vim +++ b/syntax_checkers/haskell/hdevtools.vim @@ -21,6 +21,7 @@ set cpo&vim function! SyntaxCheckers_haskell_hdevtools_GetLocList() dict let makeprg = self.makeprgBuild({ \ 'exe': self.getExecEscaped() . ' check', + \ 'fname': syntastic#util#shexpand('%:p'), \ 'args': get(g:, 'hdevtools_options', '') }) let errorformat= '\%-Z\ %#,'. diff --git a/syntax_checkers/haskell/hlint.vim b/syntax_checkers/haskell/hlint.vim index e859d299..a6714c48 100644 --- a/syntax_checkers/haskell/hlint.vim +++ b/syntax_checkers/haskell/hlint.vim @@ -14,7 +14,8 @@ let s:save_cpo = &cpo set cpo&vim function! SyntaxCheckers_haskell_hlint_GetLocList() dict - let makeprg = self.makeprgBuild({}) + let makeprg = self.makeprgBuild({ + \ 'fname': syntastic#util#shexpand('%:p')}) let errorformat = \ '%E%f:%l:%c: Error: %m,' .