diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2015-01-23 05:26:38 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2015-01-23 05:26:38 +0000 |
commit | 6565e92f3f94cfa7d2c1d5127411c23e9bd27192 (patch) | |
tree | 69458b7eee06b02a69a9c51b18aeedeee50580bd /clang/lib/CodeGen/CodeGenModule.h | |
parent | 5fa925ebf646263593c28be1b780935e11d5f732 (diff) | |
download | bcm5719-llvm-6565e92f3f94cfa7d2c1d5127411c23e9bd27192.tar.gz bcm5719-llvm-6565e92f3f94cfa7d2c1d5127411c23e9bd27192.zip |
[pr22293] Don't crash during codegen of a recursive destructor.
In ItaniumCXXABI::EmitCXXDestructors we first emit the base destructor
and then try to emit the complete one as an alias.
If in the base ends up calling the complete destructor, the GD for the
complete will be in the list of deferred decl by the time we replace
it with an alias and delete the original GV.
llvm-svn: 226896
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.h')
-rw-r--r-- | clang/lib/CodeGen/CodeGenModule.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.h b/clang/lib/CodeGen/CodeGenModule.h index 4559aecff12..81b758a7396 100644 --- a/clang/lib/CodeGen/CodeGenModule.h +++ b/clang/lib/CodeGen/CodeGenModule.h @@ -324,7 +324,7 @@ private: /// referenced. These get code generated when the module is done. struct DeferredGlobal { DeferredGlobal(llvm::GlobalValue *GV, GlobalDecl GD) : GV(GV), GD(GD) {} - llvm::AssertingVH<llvm::GlobalValue> GV; + llvm::TrackingVH<llvm::GlobalValue> GV; GlobalDecl GD; }; std::vector<DeferredGlobal> DeferredDeclsToEmit; |