tools: Unify how verifyModule() is called

Unify the error messages for the various tools when `verifyModule()`
fails on an input module.  The "brave new way" is:

    lltool: path/to/input.ll: error: input module is broken!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233667 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Duncan P. N. Exon Smith
2015-03-31 03:07:23 +00:00
parent 8ffc5ca532
commit 4e5fdbfc61
6 changed files with 15 additions and 11 deletions

View File

@@ -354,7 +354,8 @@ int main(int argc, char **argv) {
// pass pipelines. Otherwise we can crash on broken code during
// doInitialization().
if (!NoVerify && verifyModule(*M, &errs())) {
errs() << argv[0] << ": " << InputFilename << ": error: does not verify\n";
errs() << argv[0] << ": " << InputFilename
<< ": error: input module is broken!\n";
return 1;
}