summaryrefslogtreecommitdiff
path: root/lib/CodeGen/CGCXX.cpp
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2015-09-14 18:02:04 +0000
committerDavid Blaikie <dblaikie@gmail.com>2015-09-14 18:02:04 +0000
commit865e98e8e728d4bf9b6e5ca95f75b99b0c59ebf6 (patch)
tree983f7bcf8c250107f9db2d1245fe756eac423e81 /lib/CodeGen/CGCXX.cpp
parentc4c3e1f8440dbea1294cef9590454ab390259c8c (diff)
downloadclang-865e98e8e728d4bf9b6e5ca95f75b99b0c59ebf6.tar.gz
Revert "[opaque pointer type] update for LLVM API change"
This was the wrong direction to take anyway (because ultimately the GlobalValue needed the pointee type again and /it/ used PointerType::getElementType eventually anyway)... let's go a different way. This reverts commit r236161. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@247586 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGCXX.cpp')
-rw-r--r--lib/CodeGen/CGCXX.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/CGCXX.cpp b/lib/CodeGen/CGCXX.cpp
index 07eb91582a..0314b7c619 100644
--- a/lib/CodeGen/CGCXX.cpp
+++ b/lib/CodeGen/CGCXX.cpp
@@ -185,8 +185,8 @@ bool CodeGenModule::TryEmitDefinitionAsAlias(GlobalDecl AliasDecl,
return true;
// Create the alias with no name.
- auto *Alias =
- llvm::GlobalAlias::create(AliasType, Linkage, "", Aliasee, &getModule());
+ auto *Alias = llvm::GlobalAlias::create(AliasType->getElementType(), 0,
+ Linkage, "", Aliasee, &getModule());
// Switch any previous uses to the alias.
if (Entry) {