summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenFunction.cpp
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-08-08 23:24:23 +0000
committerAnders Carlsson <andersca@mac.com>2009-08-08 23:24:23 +0000
commitb8be93fc92c684a331a1ad40b30c77de3c18a67a (patch)
treef27bb74a30944cd5ce4ab45f693f6cf96e84e7e3 /clang/lib/CodeGen/CodeGenFunction.cpp
parentcfed3005e5c9d8ff26ee53ef4f9e459a2106c11d (diff)
downloadbcm5719-llvm-b8be93fc92c684a331a1ad40b30c77de3c18a67a.tar.gz
bcm5719-llvm-b8be93fc92c684a331a1ad40b30c77de3c18a67a.zip
Add support for global initializers.
llvm-svn: 78515
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenFunction.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp
index eae6161e8e1..0b012592e4f 100644
--- a/clang/lib/CodeGen/CodeGenFunction.cpp
+++ b/clang/lib/CodeGen/CodeGenFunction.cpp
@@ -173,7 +173,7 @@ void CodeGenFunction::StartFunction(const Decl *D, QualType RetTy,
// FIXME: The cast here is a huge hack.
if (CGDebugInfo *DI = getDebugInfo()) {
DI->setLocation(StartLoc);
- if (const FunctionDecl *FD = dyn_cast<FunctionDecl>(D)) {
+ if (const FunctionDecl *FD = dyn_cast_or_null<FunctionDecl>(D)) {
DI->EmitFunctionStart(CGM.getMangledName(FD), RetTy, CurFn, Builder);
} else {
// Just use LLVM function name.
OpenPOWER on IntegriCloud