Fix bug: FunctionResolve/2002-11-07-RetMismatch.ll

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4618 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2002-11-08 00:38:20 +00:00
parent a91f8ca884
commit 6f23963adc

View File

@ -251,8 +251,7 @@ static bool ProcessGlobalsWithSameName(Module &M,
// to 'int (int)' or 'int ()' or whatever else is not completely generic.
//
Function *F = cast<Function>(Globals[i]);
if (!F->getFunctionType()->isVarArg() ||
F->getFunctionType()->getNumParams()) {
if (!F->isExternal()) {
if (Concrete)
return false; // Found two different functions types. Can't choose!