improve verifier error about unterminated block to include

function name, patch by Yuri

llvm-svn: 105887
This commit is contained in:
Chris Lattner 2010-06-12 15:50:24 +00:00
parent 05466ef7eb
commit 2ed39551a7
1 changed files with 2 additions and 1 deletions

View File

@ -85,7 +85,8 @@ namespace { // Anonymous namespace for class
for (Function::iterator I = F.begin(), E = F.end(); I != E; ++I) {
if (I->empty() || !I->back().isTerminator()) {
dbgs() << "Basic Block does not have terminator!\n";
dbgs() << "Basic Block in function '" << F.getName()
<< "' does not have terminator!\n";
WriteAsOperand(dbgs(), I, true);
dbgs() << "\n";
Broken = true;