From cbbe83645a4d2569338ba213747a974d58eb6316 Mon Sep 17 00:00:00 2001
From: Andreas Louv <andreas@louv.dk>
Date: Tue, 4 Apr 2023 00:06:17 +0200
Subject: [PATCH] Print error when no alternate file can be found

---
 autoload/lsp/lspserver.vim | 1 +
 1 file changed, 1 insertion(+)

diff --git a/autoload/lsp/lspserver.vim b/autoload/lsp/lspserver.vim
index d890903..2209825 100644
--- a/autoload/lsp/lspserver.vim
+++ b/autoload/lsp/lspserver.vim
@@ -698,6 +698,7 @@ def SwitchSourceHeader(lspserver: dict<any>)
   param.uri = util.LspFileToUri(@%)
   var reply = lspserver.rpc('textDocument/switchSourceHeader', param)
   if reply->empty() || reply.result->empty()
+    util.WarnMsg('Error: No alternate file found')
     return
   endif
 
-- 
2.51.0