diff options
author | Steve Naroff <snaroff@apple.com> | 2008-02-01 23:31:13 +0000 |
---|---|---|
committer | Steve Naroff <snaroff@apple.com> | 2008-02-01 23:31:13 +0000 |
commit | 27e2eb40b9adc876c05e0260d1100385c9f0e5f5 (patch) | |
tree | bd46eda3779fe0eea57539021591290bad9acfbd /include/clang/Basic/SourceManager.h | |
parent | 2cec15fc2f3aba0939043747204c95531219de37 (diff) |
Make sure SourceManager/HeaderSearch don't support default copy constructors (since they result in bad runtime behavior).
I'm sure there are other classes that might need this "guard", however I was bitten by these 2 recently (so I thought I'd fix them).
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46653 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Basic/SourceManager.h')
-rw-r--r-- | include/clang/Basic/SourceManager.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/clang/Basic/SourceManager.h b/include/clang/Basic/SourceManager.h index add8d50729..5e7cc75579 100644 --- a/include/clang/Basic/SourceManager.h +++ b/include/clang/Basic/SourceManager.h @@ -227,6 +227,9 @@ public: SourceManager() : LastLineNoFileIDQuery(~0U), MainFileID(0) {} ~SourceManager() {} + // SourceManager doesn't support copy construction. + explicit SourceManager(const SourceManager&); + void clearIDTables() { FileIDs.clear(); MacroIDs.clear(); |