mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-06 12:44:23 +08:00
Adds an option to pass additional arguments to the verilog/verilator … (#698)
* Adds an option to pass additional arguments to the verilog/verilator linter The new otion is g:ale_verilog_verilator_options + doc * Spell check verilog linter doc file * Add entries to the verilog linters in the doc table of content * Vader test for verilog/verilator linter args option verilog_verilator_options
This commit is contained in:
@@ -1,6 +1,11 @@
|
||||
" Author: Masahiro H https://github.com/mshr-h
|
||||
" Description: verilator for verilog files
|
||||
|
||||
" Set this option to change Verilator lint options
|
||||
if !exists('g:ale_verilog_verilator_options')
|
||||
let g:ale_verilog_verilator_options = ''
|
||||
endif
|
||||
|
||||
function! ale_linters#verilog#verilator#GetCommand(buffer) abort
|
||||
let l:filename = tempname() . '_verilator_linted.v'
|
||||
|
||||
@@ -8,7 +13,9 @@ function! ale_linters#verilog#verilator#GetCommand(buffer) abort
|
||||
call ale#engine#ManageFile(a:buffer, l:filename)
|
||||
call writefile(getbufline(a:buffer, 1, '$'), l:filename)
|
||||
|
||||
return 'verilator --lint-only -Wall -Wno-DECLFILENAME ' . ale#Escape(l:filename)
|
||||
return 'verilator --lint-only -Wall -Wno-DECLFILENAME '
|
||||
\ . ale#Var(a:buffer, 'verilog_verilator_options') .' '
|
||||
\ . ale#Escape(l:filename)
|
||||
endfunction
|
||||
|
||||
function! ale_linters#verilog#verilator#Handle(buffer, lines) abort
|
||||
|
||||
Reference in New Issue
Block a user