summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-09-10 23:43:36 +0000
committerAnders Carlsson <andersca@mac.com>2009-09-10 23:43:36 +0000
commitecf9bf0158835d6be37905a71d50d6a43f071968 (patch)
tree5c66a00ea86b3a012881a882bedcb717d36499e9 /clang/lib/CodeGen/CodeGenModule.cpp
parent38988d7ee0b8ae70331a90e90c706ba0524679f3 (diff)
downloadbcm5719-llvm-ecf9bf0158835d6be37905a71d50d6a43f071968.tar.gz
bcm5719-llvm-ecf9bf0158835d6be37905a71d50d6a43f071968.zip
GlobalDecl doesn't have an explicit constructor anymore.
llvm-svn: 81481
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 37e283a9b63..064f3efcc59 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -743,7 +743,7 @@ void CodeGenModule::DeferredCopyAssignmentToEmit(GlobalDecl CopyAssignDecl) {
if (!BaseClassDecl->hasTrivialCopyAssignment() &&
!BaseClassDecl->hasUserDeclaredCopyAssignment() &&
BaseClassDecl->hasConstCopyAssignment(getContext(), MD))
- GetAddrOfFunction(GlobalDecl(MD), 0);
+ GetAddrOfFunction(MD, 0);
}
for (CXXRecordDecl::field_iterator Field = ClassDecl->field_begin(),
@@ -761,7 +761,7 @@ void CodeGenModule::DeferredCopyAssignmentToEmit(GlobalDecl CopyAssignDecl) {
if (!FieldClassDecl->hasTrivialCopyAssignment() &&
!FieldClassDecl->hasUserDeclaredCopyAssignment() &&
FieldClassDecl->hasConstCopyAssignment(getContext(), MD))
- GetAddrOfFunction(GlobalDecl(MD), 0);
+ GetAddrOfFunction(MD, 0);
}
}
DeferredDeclsToEmit.push_back(CopyAssignDecl);
@@ -919,7 +919,7 @@ void CodeGenModule::EmitTentativeDefinition(const VarDecl *D) {
// later.
const char *MangledName = getMangledName(D);
if (GlobalDeclMap.count(MangledName) == 0) {
- DeferredDecls[MangledName] = GlobalDecl(D);
+ DeferredDecls[MangledName] = D;
return;
}
}
@@ -1640,10 +1640,11 @@ void CodeGenModule::EmitTopLevelDecl(Decl *D) {
if (cast<FunctionDecl>(D)->getDescribedFunctionTemplate())
return;
- // Fall through
-
+ EmitGlobal(cast<FunctionDecl>(D));
+ break;
+
case Decl::Var:
- EmitGlobal(GlobalDecl(cast<VarDecl>(D)));
+ EmitGlobal(cast<VarDecl>(D));
break;
// C++ Decls
OpenPOWER on IntegriCloud