Fix #257 in preparation for #427, standardise options with fallbacks, and make it so every value can be computed dynamically

This commit is contained in:
w0rp
2017-04-15 13:35:54 +01:00
parent 2f009690c3
commit 706dd050f2
16 changed files with 69 additions and 36 deletions

View File

@@ -52,12 +52,16 @@ function! ale_linters#fortran#gcc#Handle(buffer, lines) abort
return l:output
endfunction
function! ale_linters#fortran#gcc#GetCommand(buffer) abort
return 'gcc -S -x f95 -fsyntax-only -ffree-form '
\ . g:ale_fortran_gcc_options
\ . ' -'
endfunction
call ale#linter#Define('fortran', {
\ 'name': 'gcc',
\ 'output_stream': 'stderr',
\ 'executable': 'gcc',
\ 'command': 'gcc -S -x f95 -fsyntax-only -ffree-form '
\ . g:ale_fortran_gcc_options
\ . ' -',
\ 'command_callback': 'ale_linters#fortran#gcc#GetCommand',
\ 'callback': 'ale_linters#fortran#gcc#Handle',
\})