[clangd] Fix targetDecl() on certain usage of ObjC properties.
authorSam McCall <sam.mccall@gmail.com>
Fri, 10 Jan 2020 09:40:30 +0000 (10:40 +0100)
committerSam McCall <sam.mccall@gmail.com>
Fri, 10 Jan 2020 17:07:24 +0000 (18:07 +0100)
commit4c5a4514d14537cae5459e03d1fea422664b3bc2
tree5acda91e525453096605293ddd825c24bf663dff
parentfbb64aa69835c8e3e9efe0afc8a73058b5a0fb3c
[clangd] Fix targetDecl() on certain usage of ObjC properties.

Summary:
In particular there's a common chain:
  OpaqueValueExpr->PseudoObjectExpr->ObjCPropertyRefExpr->ObjCPropertyDecl
and we weren't handling the first two edges

Reviewers: dgoldman, kadircet

Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, jfb, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D72494
clang-tools-extra/clangd/FindTarget.cpp
clang-tools-extra/clangd/unittests/FindTargetTests.cpp