]> granicus.if.org Git - clang/commitdiff
fix test/PCH/method_pool.m
authorChris Lattner <sabre@nondot.org>
Mon, 27 Apr 2009 22:17:41 +0000 (22:17 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 27 Apr 2009 22:17:41 +0000 (22:17 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70263 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Frontend/PCHReader.cpp

index 7ca0300eed1ee1d64db278df7ff2ab26a99ebdf1..24e4e2b02fb3d34cc35bd71d0b93182c46fb092b 100644 (file)
@@ -270,7 +270,7 @@ public:
     // Read all of the declarations visible at global scope with this
     // name.
     Sema *SemaObj = Reader.getSema();
-    if (!SemaObj) return II;
+    if (Reader.getContext() == 0) return II;
     
     while (DataLen > 0) {
       NamedDecl *D = cast<NamedDecl>(Reader.GetDecl(ReadUnalignedLE32(d)));