From 8d6fe0d6c2a14eb136e78771816ad0c8fa700d67 Mon Sep 17 00:00:00 2001 From: Dag Odenhall Date: Tue, 27 Mar 2012 13:21:59 +0200 Subject: [PATCH] haskell: configurable ghc-mod arguments, default to support for HSP --- syntax_checkers/haskell.vim | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/syntax_checkers/haskell.vim b/syntax_checkers/haskell.vim index 07c55e8b..45e97dbb 100644 --- a/syntax_checkers/haskell.vim +++ b/syntax_checkers/haskell.vim @@ -19,11 +19,16 @@ if !executable("ghc-mod") finish endif +if !exists('g:syntastic_haskell_checker_args') + let g:syntastic_haskell_checker_args = '--hlintOpt="--language=XmlSyntax"' +endif + function! SyntaxCheckers_haskell_GetLocList() + let ghcmod = 'ghc-mod ' . g:syntastic_haskell_checker_args let makeprg = \ "{ ". - \ "ghc-mod check ". shellescape(expand('%')) . "; " . - \ "ghc-mod lint " . shellescape(expand('%')) . ";" . + \ ghcmod . " check ". shellescape(expand('%')) . "; " . + \ ghcmod . " lint " . shellescape(expand('%')) . ";" . \ " }" let errorformat = '%-G\\s%#,%f:%l:%c:%trror: %m,%f:%l:%c:%tarning: %m,'. \ '%f:%l:%c: %trror: %m,%f:%l:%c: %tarning: %m,%f:%l:%c:%m,'.