1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

Fix a fairly nasty bug that prevented bugpoint from working quite right when

hacking on programs with two functions that have the same name.

llvm-svn: 12604
This commit is contained in:
Chris Lattner 2004-04-02 06:30:33 +00:00
parent b3f5ab8d5b
commit 54aa691a5c

View File

@ -195,7 +195,9 @@ Module *llvm::SplitFunctionsOutOfModule(Module *M,
bool funcFound = false;
for (std::vector<Function*>::const_iterator FI = F.begin(), Fe = F.end();
FI != Fe; ++FI)
if (I->getName() == (*FI)->getName()) funcFound = true;
if (I->getName() == (*FI)->getName() &&
I->getType() == (*FI)->getType())
funcFound = true;
if (!funcFound)
DeleteFunctionBody(I);