cling/patches/clang-CodeGen.diff
Axel Naumann 05d4e8f8d9 Improve patch paths.
git-svn-id: http://root.cern.ch/svn/root/trunk@49365 27541ba8-7e3a-0410-8455-c3a389f83636
2013-04-26 12:11:20 +00:00

33 lines
1.5 KiB
Diff

--- ./tools/clang/lib/CodeGen/CodeGenModule.cpp 2013-04-11 09:34:53.217172752 +0200
+++ ./tools/clang/lib/CodeGen/CodeGenModule.cpp 2013-04-24 19:40:15.333490079 +0200
@@ -477,7 +477,7 @@
GlobalDtors.push_back(std::make_pair(Dtor, Priority));
}
-void CodeGenModule::EmitCtorList(const CtorList &Fns, const char *GlobalName) {
+void CodeGenModule::EmitCtorList(CtorList &Fns, const char *GlobalName) {
// Ctor function type is void()*.
llvm::FunctionType* CtorFTy = llvm::FunctionType::get(VoidTy, false);
llvm::Type *CtorPFTy = llvm::PointerType::getUnqual(CtorFTy);
@@ -503,6 +503,7 @@
llvm::ConstantArray::get(AT, Ctors),
GlobalName);
}
+ Fns.clear();
}
llvm::GlobalValue::LinkageTypes
--- ./tools/clang/lib/CodeGen/CodeGenModule.h 2013-04-11 09:34:53.233172585 +0200
+++ ./tools/clang/lib/CodeGen/CodeGenModule.h 2013-04-24 19:40:15.325490142 +0200
@@ -1035,8 +1035,8 @@
/// EmitCtorList - Generates a global array of functions and priorities using
/// the given list and name. This array will have appending linkage and is
- /// suitable for use as a LLVM constructor or destructor array.
- void EmitCtorList(const CtorList &Fns, const char *GlobalName);
+ /// suitable for use as a LLVM constructor or destructor array. Clears Fns.
+ void EmitCtorList(CtorList &Fns, const char *GlobalName);
/// EmitFundamentalRTTIDescriptor - Emit the RTTI descriptors for the
/// given type.