[PATCH] D119366: [clangd] Use `ObjCProtocolLoc` for generalized ObjC protocol support
Sam McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Feb 10 14:07:45 PST 2022
sammccall accepted this revision.
sammccall added inline comments.
================
Comment at: clang-tools-extra/clangd/unittests/FindTargetTests.cpp:948
Code = R"cpp(
+ void test(id</*error-ok*/[[InvalidProtocol]]> p);
----------------
dgoldman wrote:
> sammccall wrote:
> > This new test case looks interesting, but can we keep the old one too?
> It now fails, I thought this was expected since the selection is now split up into multiple nodes - should it continue to work as it did previously?
>
> ```
> llvm-project/clang-tools-extra/clangd/unittests/FindTargetTests.cpp:953: Failure
> Value of: assertNodeAndPrintDecls("ObjCObjectTypeLoc")
> Expected: has 1 element and that element is equal to @protocol Foo Rel=
> Actual: {}
>
> @protocol Foo
> @end
> void test([[id<Foo>]] p);
> ```
Oops, I wasn't reading carefully enough, you're right!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D119366/new/
https://reviews.llvm.org/D119366
More information about the cfe-commits
mailing list