diff options
author | Ted Kremenek <kremenek@apple.com> | 2008-11-13 17:11:24 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2008-11-13 17:11:24 +0000 |
commit | a0d2a1661a89159e845126419e742c5a5d9444d6 (patch) | |
tree | c241cc45ad3d81b70d3196c9e85d88bbf8a8587c /clang/lib/Lex/Preprocessor.cpp | |
parent | 7c1e61d78bebdb16b029b20d701585e75ee8bf5c (diff) | |
download | bcm5719-llvm-a0d2a1661a89159e845126419e742c5a5d9444d6.tar.gz bcm5719-llvm-a0d2a1661a89159e845126419e742c5a5d9444d6.zip |
Using llvm::OwningPtr<> for CurLexer and CurTokenLexer. This makes both the ownership semantics of these objects explicit within the Preprocessor and also tightens up the code (explicit deletes not needed).
llvm-svn: 59249
Diffstat (limited to 'clang/lib/Lex/Preprocessor.cpp')
-rw-r--r-- | clang/lib/Lex/Preprocessor.cpp | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/clang/lib/Lex/Preprocessor.cpp b/clang/lib/Lex/Preprocessor.cpp index 901bcd08ce3..c65b5462098 100644 --- a/clang/lib/Lex/Preprocessor.cpp +++ b/clang/lib/Lex/Preprocessor.cpp @@ -87,9 +87,6 @@ Preprocessor::Preprocessor(Diagnostic &diags, const LangOptions &opts, Preprocessor::~Preprocessor() { assert(BacktrackPositions.empty() && "EnableBacktrack/Backtrack imbalance!"); - // Free any active lexers. - delete CurLexer; - while (!IncludeMacroStack.empty()) { delete IncludeMacroStack.back().TheLexer; delete IncludeMacroStack.back().TheTokenLexer; |