Describe the bug
When a file has diagnostic errors and they all get resolved, the server gives invalid URI (missing file:/ prefix).
To Reproduce
Open any c3 source file
Cause an error (for example remove ;)
Save
Fix the error
Save
Diagnostics with invald URI should be sent from the LSP
Expected behavior
The URI should be correct and error should just disappear.
Screenshots
Desktop (please complete the following information):
OS: NixOS
Editor: neovim
Additional context
I tried fixing this myself, but this required moving the clearOldDiagnostics under the Server struct so I'm not sure if it's the right way to do this (I have pretty much zero experience in Go).
Describe the bug When a file has diagnostic errors and they all get resolved, the server gives invalid URI (missing
file:/
prefix).To Reproduce
;
)Expected behavior The URI should be correct and error should just disappear.
Screenshots
Desktop (please complete the following information):
Additional context I tried fixing this myself, but this required moving the
clearOldDiagnostics
under theServer
struct so I'm not sure if it's the right way to do this (I have pretty much zero experience in Go).I have my fix in a commit https://github.com/tomaskallup/c3-lsp/commit/489f24eaea3c66cfc9db621387313dc7d779efde, tested it after rebuilding and everything seemed fine. The fix is tiny, so if it's correct, feel free to just commit it here, I could create a PR, but I would have to cherry-pick it into a fresh branch.