diff options
author | Chris Lattner <sabre@nondot.org> | 2003-11-21 20:33:27 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2003-11-21 20:33:27 +0000 |
commit | afd0b4b24af31734d951d1723f60f0f4c841f6ea (patch) | |
tree | c46df03da5ea37313a541d50b8268ee0d528dd79 | |
parent | ae711a8b48765c6442bfccdce794a466a557480f (diff) |
Fix problem Reid was having with external globals and nonexternal linkage
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10133 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/VMCore/Verifier.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/VMCore/Verifier.cpp b/lib/VMCore/Verifier.cpp index 48384e882c..1d441d1dd5 100644 --- a/lib/VMCore/Verifier.cpp +++ b/lib/VMCore/Verifier.cpp @@ -108,8 +108,7 @@ namespace { // Anonymous namespace for class visitGlobalValue(*I); for (Module::giterator I = M.gbegin(), E = M.gend(); I != E; ++I) - if (I->isExternal() && I->hasInternalLinkage()) - CheckFailed("Global Variable is external with internal linkage!", I); + visitGlobalValue(*I); // If the module is broken, abort at this time. abortIfBroken(); @@ -203,7 +202,7 @@ namespace { // Anonymous namespace for class void Verifier::visitGlobalValue(GlobalValue &GV) { Assert1(!GV.isExternal() || GV.hasExternalLinkage(), - "Global value has Internal Linkage!", &GV); + "Global is external, but doesn't have external linkage!", &GV); Assert1(!GV.hasAppendingLinkage() || isa<GlobalVariable>(GV), "Only global variables can have appending linkage!", &GV); |