llvm-project
545917cb - [clangd] Harden incomingCalls() against possible misinterpretation of a range as pertaining to the wrong file (#111616)

Commit
319 days ago
[clangd] Harden incomingCalls() against possible misinterpretation of a range as pertaining to the wrong file (#111616) `CallHierarchyIncomingCall::fromRanges` are interpreted as ranges in the same file as the `CallHierarchyItem` representing the caller (`CallHierarchyIncomingCall::from`). In C/C++, it's possible for the calls to be in a different file than the caller, as illustrated in the added test case. With this patch, such calls are dropped, rather than their ranges being incorrectly interpreted as pertaining to the wrong file.
Parents
Loading