Fix #572 - Link to whatever SignColumn links to for ALESignColumnWithoutErrors

This commit is contained in:
w0rp
2017-05-22 09:34:25 +01:00
parent c8ce15d9f1
commit 71bf2bfb94
2 changed files with 36 additions and 9 deletions

View File

@@ -34,8 +34,15 @@ if !hlexists('ALESignColumnWithoutErrors')
silent highlight SignColumn
redir end
execute 'highlight ALESignColumnWithoutErrors '
\ . join(split(l:output)[2:])
let l:highlight_syntax = join(split(l:output)[2:])
let l:match = matchlist(l:highlight_syntax, '\vlinks to (.+)$')
if !empty(l:match)
execute 'highlight link ALESignColumnWithoutErrors ' . l:match[1]
else
execute 'highlight ALESignColumnWithoutErrors ' . l:highlight_syntax
endif
endfunction
call s:SetSignColumnWithoutErrorsHighlight()