aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/clang/AST/DeclObjC.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/clang/AST/DeclObjC.h b/include/clang/AST/DeclObjC.h
index 136acf377f..b717af0d01 100644
--- a/include/clang/AST/DeclObjC.h
+++ b/include/clang/AST/DeclObjC.h
@@ -592,6 +592,12 @@ public:
SourceLocation ClassLoc = SourceLocation(),
bool ForwardDecl = false,
bool isInternal = false);
+
+ virtual SourceRange getSourceRange() const {
+ if (isForwardDecl())
+ return SourceRange(getAtStartLoc(), getLocation());
+ return ObjCContainerDecl::getSourceRange();
+ }
/// \brief Indicate that this Objective-C class is complete, but that
/// the external AST source will be responsible for filling in its contents