diff --git a/llvm/lib/Linker/LinkModules.cpp b/llvm/lib/Linker/LinkModules.cpp index 85caa20464c7..0504580ddbbf 100644 --- a/llvm/lib/Linker/LinkModules.cpp +++ b/llvm/lib/Linker/LinkModules.cpp @@ -469,8 +469,8 @@ static bool LinkGlobals(Module *Dest, Module *Src, if (DGV && DGV->hasInternalLinkage()) DGV = 0; - assert(SGV->hasInitializer() || SGV->hasExternalWeakLinkage() || - SGV->hasExternalLinkage() || SGV->hasDLLImportLinkage() && + assert((SGV->hasInitializer() || SGV->hasExternalWeakLinkage() || + SGV->hasExternalLinkage() || SGV->hasDLLImportLinkage()) && "Global must either be external or have an initializer!"); GlobalValue::LinkageTypes NewLinkage = GlobalValue::InternalLinkage;