From 16bef857d91ad9328874b85f59edd04155aa9579 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Fri, 16 Oct 2009 20:01:17 +0000 Subject: Keep track of whether declararions were loaded from a precompiled header or not via a new "PCHLevel" field in Decl. We currently use this information to help CIndex filter out declarations that came from a precompiled header (rather than from an AST file). Further down the road, it can be used to help implement multi-level precompiled headers. llvm-svn: 84267 --- clang/lib/Frontend/PCHReaderDecl.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'clang/lib/Frontend/PCHReaderDecl.cpp') diff --git a/clang/lib/Frontend/PCHReaderDecl.cpp b/clang/lib/Frontend/PCHReaderDecl.cpp index b6732561dff..ed6728233a9 100644 --- a/clang/lib/Frontend/PCHReaderDecl.cpp +++ b/clang/lib/Frontend/PCHReaderDecl.cpp @@ -86,6 +86,7 @@ void PCHDeclReader::VisitDecl(Decl *D) { D->setImplicit(Record[Idx++]); D->setUsed(Record[Idx++]); D->setAccess((AccessSpecifier)Record[Idx++]); + D->setPCHLevel(Record[Idx++] + 1); } void PCHDeclReader::VisitTranslationUnitDecl(TranslationUnitDecl *TU) { -- cgit v1.2.3