diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2008-05-30 11:28:30 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2008-05-30 11:28:30 +0000 |
commit | 9b5239339d3b42c20a2cbb0843445ed98e1fea2b (patch) | |
tree | 4a2e507cf161c469f156947d3e71f4bcf3b0cbf7 /Driver/ASTConsumers.cpp | |
parent | 109603de14dfe69f3eb9b264a273b38e5684c8de (diff) |
Fix crash with -serialize (reported to cfe-dev). The issue was
essentially that we were destroying the declarations twice.
(Note that we don't use -serialize directly in the testsuite, only
SerializeTest.)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51768 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Driver/ASTConsumers.cpp')
-rw-r--r-- | Driver/ASTConsumers.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Driver/ASTConsumers.cpp b/Driver/ASTConsumers.cpp index 3383dd38fd..ba9fc90f03 100644 --- a/Driver/ASTConsumers.cpp +++ b/Driver/ASTConsumers.cpp @@ -879,6 +879,7 @@ public: virtual void Initialize(ASTContext &Context) { if (!TU) TU = new TranslationUnit(Context, lang); + TU->SetOwnsDecls(false); } virtual void HandleTopLevelDecl(Decl *D) { |