Last active
December 12, 2015 12:48
-
-
Save scrooloose/4774347 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"notes: | |
"syntastic looks for these functions: | |
" | |
" SyntaxCheckers_FILETYPE_NAME_IsAvailable() | |
" SyntaxCheckers_FILETYPE_NAME_GetLocList() | |
" | |
" In your code below, FILETYPE is verilog_systemverilog, and NAME is sv_compiler (i | |
" removed the "my " from the beginning). | |
" | |
" I have changed the function names to match, so it should work now :) | |
function! SyntaxCheckers_verilog_systemverilog_sv_compiler_IsAvailable() | |
return executable("my sv_compiler") | |
endfunction | |
if !exists('g:verilog_systemverilog_checker') | |
let g:verilog_systemverilog_checker = "my sv_compiler" | |
endfunction | |
function! SyntaxCheckers_verilog_systemverilog_sv_compiler_GetLocList() | |
let makeprg = g:verilog_systemverilog_checker . 'list of arg | |
files' .shellescape(expand('%')) . 'list of post arg files' | |
let errorformat = '"%f", %l: %m' | |
return SyntasticMake({ 'makeprg': makeprg, 'errorformat': errorformat}) | |
endfunction | |
call g:SyntasticRegistry.CreateAndRegisterChecker({ | |
\ 'filetype': 'verilog_systemverilog', | |
\ 'name': 'sv_compiler'}) |
Wow that was a very quick relpy. First class support :) !! My question now is that what if my executable has a '.' in its name. For exmaple it looks like my_compiler.compiler. Would that affect the SyntaxCheckers_FILETYPE_NAME_GetLocList() function call ?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
you may want to change NAME to
my_sv_compiler
if that seems more sensible :)