summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar/LowerGC.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Transforms/Scalar/LowerGC.cpp')
-rw-r--r--llvm/lib/Transforms/Scalar/LowerGC.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/LowerGC.cpp b/llvm/lib/Transforms/Scalar/LowerGC.cpp
index fa06bd0dfcb..a98981359d1 100644
--- a/llvm/lib/Transforms/Scalar/LowerGC.cpp
+++ b/llvm/lib/Transforms/Scalar/LowerGC.cpp
@@ -130,7 +130,7 @@ bool LowerGC::doInitialization(Module &M) {
GlobalValue::LinkOnceLinkage,
Constant::getNullValue(PRLTy),
"llvm_gc_root_chain", &M);
- } else if (RootChain->hasExternalLinkage() && RootChain->isExternal()) {
+ } else if (RootChain->hasExternalLinkage() && RootChain->isDeclaration()) {
RootChain->setInitializer(Constant::getNullValue(PRLTy));
RootChain->setLinkage(GlobalValue::LinkOnceLinkage);
}
OpenPOWER on IntegriCloud