From: Sebastian Redl Date: Tue, 13 Jul 2010 20:12:07 +0000 (+0000) Subject: Add two small utility functions to PCHReader that the writer will use. WIP. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=77a3c9ede5cdb26b5eb3001e82bb0a36ca997e1f;p=clang Add two small utility functions to PCHReader that the writer will use. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108267 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Frontend/PCHReader.h b/include/clang/Frontend/PCHReader.h index 38402732a3..461d254817 100644 --- a/include/clang/Frontend/PCHReader.h +++ b/include/clang/Frontend/PCHReader.h @@ -602,6 +602,16 @@ public: /// \brief Read preprocessed entities into the virtual void ReadPreprocessedEntities(); + /// \brief Returns the number of types found in this file. + unsigned getTotalNumTypes() const { + return static_cast(TypesLoaded.size()); + } + + /// \brief Returns the number of declarations found in this file. + unsigned getTotalNumDecls() const { + return static_cast(DeclsLoaded.size()); + } + /// \brief Reads a TemplateArgumentLocInfo appropriate for the /// given TemplateArgument kind. TemplateArgumentLocInfo