[clangd] Fix AddUsing tweak for out-of-line functions.
Summary: We used getEnclosingNamespaceContext(), which calls getParent() rather than getLexicalParent(), so we would end up adding the "using" line in places that do not affect the cursor location, or just return an error when declaration was in another file. Patch by Adam Czachorowski! Reviewers: hokein Reviewed By: hokein Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D79496
Loading
Please register or sign in to comment