aboutsummaryrefslogtreecommitdiff
path: root/lib/Index/Analyzer.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2009-09-29 19:44:27 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2009-09-29 19:44:27 +0000
commitf4526e3fd48248af78b3d59ec36a37bc055b326f (patch)
tree937143c4352bb089ece89213bf9649d7a2f2e25a /lib/Index/Analyzer.cpp
parentf352bddf015e537350416c296dd2963524f554f9 (diff)
Modify ASTLocation and apart from being a Decl or Stmt, allow it to also be:
-A NamedDecl reference -A TypeLoc git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83095 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Index/Analyzer.cpp')
-rw-r--r--lib/Index/Analyzer.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/Index/Analyzer.cpp b/lib/Index/Analyzer.cpp
index cda2c505fd..300a469220 100644
--- a/lib/Index/Analyzer.cpp
+++ b/lib/Index/Analyzer.cpp
@@ -144,16 +144,15 @@ public:
/// It returns true "eagerly", meaning it will return false only if it can
/// "prove" statically that the interface cannot accept this message.
bool ValidReference(ASTLocation ASTLoc, ObjCInterfaceDecl *IFace) {
- assert(ASTLoc.isValid());
assert(ASTLoc.isStmt());
// FIXME: Finding @selector references should be through another Analyzer
// method, like FindSelectors.
- if (isa<ObjCSelectorExpr>(ASTLoc.getStmt()))
+ if (isa<ObjCSelectorExpr>(ASTLoc.AsStmt()))
return false;
ObjCInterfaceDecl *MsgD = 0;
- ObjCMessageExpr *Msg = cast<ObjCMessageExpr>(ASTLoc.getStmt());
+ ObjCMessageExpr *Msg = cast<ObjCMessageExpr>(ASTLoc.AsStmt());
if (Msg->getReceiver()) {
const ObjCObjectPointerType *OPT =