Skip to content

Commit

Permalink
Set a lower priority for diagnostic matches
Browse files Browse the repository at this point in the history
Avoids masking `hlsearch` and potentially other highlighting with a
priority under 10.
  • Loading branch information
natebosch committed Jan 18, 2018
1 parent 83332ee commit 203f7c9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
- Improve performance of incremental diff.
- Print messages received on stderr.
- Don't open an empty quickfix list when no references are found.
- Don't mask `hlsearch` with diagnostics.

# 0.2.8

Expand Down
2 changes: 1 addition & 1 deletion autoload/lsc/highlights.vim
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function! lsc#highlights#update() abort
if &diff | return | endif
for line in values(lsc#diagnostics#forFile(expand('%:p')))
for diagnostic in line
let match = matchaddpos(diagnostic.group, diagnostic.ranges)
let match = matchaddpos(diagnostic.group, diagnostic.ranges, -1)
call add(w:lsc_diagnostic_matches, match)
endfor
endfor
Expand Down

0 comments on commit 203f7c9

Please sign in to comment.