From df90325d4c0a65ee64d2dae3ed9b5b34f7418533 Mon Sep 17 00:00:00 2001 From: rdivacky Date: Wed, 3 Mar 2010 17:28:16 +0000 Subject: Update clang to 97654. --- lib/Analysis/AnalysisContext.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'lib/Analysis/AnalysisContext.cpp') diff --git a/lib/Analysis/AnalysisContext.cpp b/lib/Analysis/AnalysisContext.cpp index ccd5088..d9933e8 100644 --- a/lib/Analysis/AnalysisContext.cpp +++ b/lib/Analysis/AnalysisContext.cpp @@ -186,6 +186,18 @@ LocationContext::getStackFrameForDeclContext(const DeclContext *DC) const { return NULL; } +bool LocationContext::isParentOf(const LocationContext *LC) const { + do { + const LocationContext *Parent = LC->getParent(); + if (Parent == this) + return true; + else + LC = Parent; + } while (LC); + + return false; +} + //===----------------------------------------------------------------------===// // Lazily generated map to query the external variables referenced by a Block. //===----------------------------------------------------------------------===// -- cgit v1.1