Commit Graph

11 Commits

Author SHA1 Message Date
Argyrios Kyrtzidis 34be01b9f4 Find references inside blocks.
llvm-svn: 77540
2009-07-29 23:40:48 +00:00
Argyrios Kyrtzidis bc6c64de44 Constify ASTLocation::print.
llvm-svn: 77532
2009-07-29 23:39:35 +00:00
Argyrios Kyrtzidis b78139f74d Handle references from ObjCIvarRefExprs.
llvm-svn: 76507
2009-07-21 00:05:38 +00:00
Zhongxing Xu 34e0370502 The children statements might be NULL. Check for this case in
isContainedInStatement().

llvm-svn: 76408
2009-07-20 08:28:49 +00:00
Argyrios Kyrtzidis d6bf03c272 Introduce ASTLocation::getReferencedDecl(), for getting the declaration that the ASTLocation references.
llvm-svn: 76336
2009-07-18 21:17:58 +00:00
Argyrios Kyrtzidis fb63b0a317 Handle invalid ASTLocations instead of asserting.
llvm-svn: 76335
2009-07-18 21:17:43 +00:00
Argyrios Kyrtzidis 38d83defbe Make ASTLocation accept a Stmt that is inside an ObjCMethodDecl.
llvm-svn: 76271
2009-07-18 00:33:46 +00:00
Zhongxing Xu 3436f58e40 As suggested by Argyrios, revert r76159 and make "FindImmediateParent"
a public static method of ASTLocation.

llvm-svn: 76166
2009-07-17 07:36:20 +00:00
Zhongxing Xu d25ea831b2 Relax the assertion in ASTLocation's ctor: if the decl is not the immediate
parent of the stmt, find the immediate parent for the stmt.

This is because sometimes we cannot get the immediate decl of the stmt when
creating the ASTLocation. We can only get a parent of the stmt.

llvm-svn: 76159
2009-07-17 06:58:08 +00:00
Argyrios Kyrtzidis b8020f0833 Some changes to ASTLocation's methods
-Change hasStmt() to isStmt()
-Add isDecl()
-Add getSourceRange()

llvm-svn: 74862
2009-07-06 21:35:20 +00:00
Argyrios Kyrtzidis 63afa49add Move ASTLocation and DeclReferenceMap from the AST library to the Index library.
llvm-svn: 74859
2009-07-06 21:34:47 +00:00