diff options
author | Nate Begeman <natebegeman@mac.com> | 2008-07-25 17:28:23 +0000 |
---|---|---|
committer | Nate Begeman <natebegeman@mac.com> | 2008-07-25 17:28:23 +0000 |
commit | 0abbe2bf155ca617b27de1411c7f3fd132ac54c2 (patch) | |
tree | 909a905bcb2fb979a692a02c1420a449a9afd184 /lib/VMCore/Verifier.cpp | |
parent | e3c8f8c53ba390c493752bf900c684b347edb235 (diff) | |
download | external_llvm-0abbe2bf155ca617b27de1411c7f3fd132ac54c2.zip external_llvm-0abbe2bf155ca617b27de1411c7f3fd132ac54c2.tar.gz external_llvm-0abbe2bf155ca617b27de1411c7f3fd132ac54c2.tar.bz2 |
Allow verifier to be run on partially materialized modules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54028 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/Verifier.cpp')
-rw-r--r-- | lib/VMCore/Verifier.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/VMCore/Verifier.cpp b/lib/VMCore/Verifier.cpp index 0aef414..4711689 100644 --- a/lib/VMCore/Verifier.cpp +++ b/lib/VMCore/Verifier.cpp @@ -332,6 +332,7 @@ void Verifier::visitGlobalValue(GlobalValue &GV) { GV.hasExternalLinkage() || GV.hasDLLImportLinkage() || GV.hasExternalWeakLinkage() || + GV.hasGhostLinkage() || (isa<GlobalAlias>(GV) && (GV.hasInternalLinkage() || GV.hasWeakLinkage())), "Global is external, but doesn't have external or dllimport or weak linkage!", @@ -510,7 +511,7 @@ void Verifier::visitFunction(Function &F) { if (F.isDeclaration()) { Assert1(F.hasExternalLinkage() || F.hasDLLImportLinkage() || - F.hasExternalWeakLinkage(), + F.hasExternalWeakLinkage() || F.hasGhostLinkage(), "invalid linkage type for function declaration", &F); } else { // Verify that this function (which has a body) is not named "llvm.*". It |