Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 916538e

Browse files
authoredDec 12, 2024
fix: drop useless/harmful nvim_set_hl_ns (#393)
The highlight absolutely does not need to be in the same namespace as the extmarks, and we definitely do not need to globally change the highlight namespace, as that might interfere with other plugins or the user's config or whatever. And it happens to break background colors in floats (such as LSP hover, diagnostic detail, completion help, etc.) due to a bug in neovim: neovim/neovim#30262
1 parent e6b78ec commit 916538e

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed
 

‎lua/iron/core.lua

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -663,8 +663,7 @@ core.setup = function(opts)
663663
}
664664

665665

666-
(vim.api.nvim__set_hl_ns or vim.api.nvim_set_hl_ns)(config.namespace)
667-
vim.api.nvim_set_hl(config.namespace, config.highlight_last, hl_cfg)
666+
vim.api.nvim_set_hl(0, config.highlight_last, hl_cfg)
668667
end
669668

670669
for _, command in ipairs(commands) do

0 commit comments

Comments
 (0)
Please sign in to comment.