summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-05-29 21:03:38 +0000
committerAnders Carlsson <andersca@mac.com>2009-05-29 21:03:38 +0000
commit0a63741a3f969f02bcd20121602e7a662933eae9 (patch)
tree2f9584624dae4b3623f18af7d08bcee132b92eab /clang/lib/CodeGen/CodeGenModule.cpp
parent7de5966d76fea50cdf1ded7ccd2677594a12ef36 (diff)
downloadbcm5719-llvm-0a63741a3f969f02bcd20121602e7a662933eae9.tar.gz
bcm5719-llvm-0a63741a3f969f02bcd20121602e7a662933eae9.zip
Add code for emitting C++ destructors. Not used yet.
llvm-svn: 72591
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 04693fd502e..b69301ed589 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -576,6 +576,8 @@ void CodeGenModule::EmitGlobalDefinition(GlobalDecl GD) {
if (const CXXConstructorDecl *CD = dyn_cast<CXXConstructorDecl>(D))
EmitCXXConstructor(CD, GD.getCtorType());
+ else if (const CXXDestructorDecl *DD = dyn_cast<CXXDestructorDecl>(D))
+ EmitCXXDestructor(DD, GD.getDtorType());
else if (isa<FunctionDecl>(D))
EmitGlobalFunctionDefinition(GD);
else if (const VarDecl *VD = dyn_cast<VarDecl>(D))
OpenPOWER on IntegriCloud