diff options
author | w0rp <devw0rp@gmail.com> | 2017-02-07 15:15:22 +0000 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2017-02-07 15:15:22 +0000 |
commit | da8408501c8bb82fb99627b7d0eba41e38146a46 (patch) | |
tree | 01a465bfd7466775ab39ec05ce2a6541c33a0b8a /ale_linters | |
parent | a3b7056cadb045906141cc342404950b6d673959 (diff) | |
download | ale-da8408501c8bb82fb99627b7d0eba41e38146a46.zip |
#256 Attempt to fix Rust linter issues
Diffstat (limited to 'ale_linters')
-rw-r--r-- | ale_linters/rust/rustc.vim | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ale_linters/rust/rustc.vim b/ale_linters/rust/rustc.vim index e31b895c..c97c40e7 100644 --- a/ale_linters/rust/rustc.vim +++ b/ale_linters/rust/rustc.vim @@ -17,14 +17,15 @@ function! ale_linters#rust#rustc#HandleRustcErrors(buffer_number, errorlines) ab endif let l:error = json_decode(l:errorline) - if !has_key(l:error, 'code') && !has_key(l:error, 'message') - continue - endif if has_key(l:error, 'message') let l:error = l:error.message endif + if !has_key(l:error, 'code') + continue + endif + if !empty(l:error.code) && index(g:ale_rust_ignore_error_codes, l:error.code.code) > -1 continue endif |