Replies: 1 comment 3 replies
|
This appears to be deliberate and introduced in https://reviews.llvm.org/D57580. |
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
The language server protocol defines the endpoints textDocument/declaration and textDocument/definition.
nonsense sample code:
Line 1 is a declaration.
Line 7 is a usage.
Line 11 is a defintion.
In line 7, clangd returns the correct declaration or definition.
However, if I send a declaration request in line 1, the definition is returned.
And if I send a definition request on line 11, it returns the declaration.
I was expecting it to return itself.
Is there a reason for this behavior?
All reactions