diff options
author | Chris Lattner <sabre@nondot.org> | 2007-07-22 06:05:44 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-07-22 06:05:44 +0000 |
commit | bd24776a825a18a59067c68a9d32f2d22e4cbf79 (patch) | |
tree | f5e670f8f278e031ae750befd3acc40fbeebd0e1 /include/clang/Basic/SourceManager.h | |
parent | 95cfb85ad1820117e0864712555f3aa4fdf4721a (diff) |
when running in -E mode on multiple files, there is no reason to accumulate
fileid's and macroid's across files. Clearing between files keeps the tables
smaller and slightly speeds up compilation.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@40383 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/SourceManager.h')
-rw-r--r-- | include/clang/Basic/SourceManager.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/clang/Basic/SourceManager.h b/include/clang/Basic/SourceManager.h index 414b1789a7..f06a6fbf54 100644 --- a/include/clang/Basic/SourceManager.h +++ b/include/clang/Basic/SourceManager.h @@ -158,6 +158,11 @@ public: SourceManager() {} ~SourceManager(); + void clearIDTables() { + FileIDs.clear(); + MacroIDs.clear(); + } + /// createFileID - Create a new FileID that represents the specified file /// being #included from the specified IncludePosition. This returns 0 on /// error and translates NULL into standard input. |