summaryrefslogtreecommitdiffstats
path: root/clang/CodeGen
diff options
context:
space:
mode:
Diffstat (limited to 'clang/CodeGen')
-rw-r--r--clang/CodeGen/CGExpr.cpp2
-rw-r--r--clang/CodeGen/CodeGenModule.cpp2
-rw-r--r--clang/CodeGen/CodeGenModule.h3
3 files changed, 4 insertions, 3 deletions
diff --git a/clang/CodeGen/CGExpr.cpp b/clang/CodeGen/CGExpr.cpp
index 86604f94bfb..64fa549a05f 100644
--- a/clang/CodeGen/CGExpr.cpp
+++ b/clang/CodeGen/CGExpr.cpp
@@ -261,7 +261,7 @@ void CodeGenFunction::EmitStoreThroughOCUComponentLValue(RValue Src, LValue Dst,
LValue CodeGenFunction::EmitDeclRefLValue(const DeclRefExpr *E) {
- const Decl *D = E->getDecl();
+ const ValueDecl *D = E->getDecl();
if (isa<BlockVarDecl>(D) || isa<ParmVarDecl>(D)) {
llvm::Value *V = LocalDeclMap[D];
assert(V && "BlockVarDecl not entered in LocalDeclMap?");
diff --git a/clang/CodeGen/CodeGenModule.cpp b/clang/CodeGen/CodeGenModule.cpp
index a26e1293362..e14b738a314 100644
--- a/clang/CodeGen/CodeGenModule.cpp
+++ b/clang/CodeGen/CodeGenModule.cpp
@@ -27,7 +27,7 @@ using namespace CodeGen;
CodeGenModule::CodeGenModule(ASTContext &C, llvm::Module &M)
: Context(C), TheModule(M), Types(C, M), CFConstantStringClassRef(0) {}
-llvm::Constant *CodeGenModule::GetAddrOfGlobalDecl(const Decl *D) {
+llvm::Constant *CodeGenModule::GetAddrOfGlobalDecl(const ValueDecl *D) {
// See if it is already in the map.
llvm::Constant *&Entry = GlobalDeclMap[D];
if (Entry) return Entry;
diff --git a/clang/CodeGen/CodeGenModule.h b/clang/CodeGen/CodeGenModule.h
index af2db808400..d94f54a8468 100644
--- a/clang/CodeGen/CodeGenModule.h
+++ b/clang/CodeGen/CodeGenModule.h
@@ -28,6 +28,7 @@ namespace clang {
class ASTContext;
class FunctionDecl;
class Decl;
+ class ValueDecl;
class FileVarDecl;
namespace CodeGen {
@@ -53,7 +54,7 @@ public:
llvm::Module &getModule() const { return TheModule; }
CodeGenTypes &getTypes() { return Types; }
- llvm::Constant *GetAddrOfGlobalDecl(const Decl *D);
+ llvm::Constant *GetAddrOfGlobalDecl(const ValueDecl *D);
/// getBuiltinLibFunction - Given a builtin id for a function like
/// "__builtin_fabsf", return a Function* for "fabsf".
OpenPOWER on IntegriCloud