[llvm-commits] [gcc-plugin] r76368 - /gcc-plugin/trunk/llvm-convert.cpp
Duncan Sands
baldrick at free.fr
Sun Jul 19 06:59:20 PDT 2009
Author: baldrick
Date: Sun Jul 19 08:59:14 2009
New Revision: 76368
URL: http://llvm.org/viewvc/llvm-project?rev=76368&view=rev
Log:
Use llvm_report_error rather than cerr + abort.
Add a "break" in case some compiler complains.
Modified:
gcc-plugin/trunk/llvm-convert.cpp
Modified: gcc-plugin/trunk/llvm-convert.cpp
URL: http://llvm.org/viewvc/llvm-project/gcc-plugin/trunk/llvm-convert.cpp?rev=76368&r1=76367&r2=76368&view=diff
==============================================================================
--- gcc-plugin/trunk/llvm-convert.cpp (original)
+++ gcc-plugin/trunk/llvm-convert.cpp Sun Jul 19 08:59:14 2009
@@ -34,6 +34,7 @@
#include "llvm/Module.h"
#include "llvm/Analysis/ConstantFolding.h"
#include "llvm/System/Host.h"
+#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/MathExtras.h"
#include "llvm/Target/TargetAsmInfo.h"
#include "llvm/Target/TargetData.h"
@@ -760,10 +761,10 @@
case GIMPLE_PREDICT:
case GIMPLE_RESX:
default:
- std::cerr << "Unknown GIMPLE statement during LLVM emission!\n"
- << "gimple_code: " << gimple_code(stmt) << "\n";
print_gimple_stmt(stderr, stmt, 4, 0);
- abort();
+ llvm_report_error("Unknown GIMPLE statement during LLVM emission!\n"
+ "gimple_code: " + gimple_code(stmt));
+ break;
}
}
More information about the llvm-commits
mailing list