From c6535538f8717a8f6134020a5bee65341cf8280f Mon Sep 17 00:00:00 2001 From: Lewis Russell Date: Mon, 28 Sep 2026 14:19:42 +0100 Subject: fix(lua): enable param-type-mismatch diagnostic Problem: Argument type mismatches are excluded from EmmyLua checks. Solution: Correct runtime annotations and calls, document local checker workarounds, and enable the diagnostic. AI-assisted --- runtime/lua/vim/net/_ssh.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'runtime/lua/vim/net/_ssh.lua') diff --git a/runtime/lua/vim/net/_ssh.lua b/runtime/lua/vim/net/_ssh.lua index 6bf55423f4..61b878cdbe 100644 --- a/runtime/lua/vim/net/_ssh.lua +++ b/runtime/lua/vim/net/_ssh.lua @@ -191,7 +191,11 @@ function M.parse_ssh_config(text) if node.param:lower() == 'match' and node.value then local current = nil for ind, val in ipairs(node.value) do - if val:lower() == 'host' and ind + 1 <= #node.value and is_valid(node.value[ind + 1]) then + if + val:lower() == 'host' + and ind + 1 <= #node.value + and is_valid(assert(node.value[ind + 1])) + then current = node.value[ind + 1] end end -- cgit