Convert more abort() calls to llvm_report_error().

Also remove trailing semicolon.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75027 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Torok Edwin
2009-07-08 19:04:27 +00:00
parent e9b11b4313
commit 804e0fea40
22 changed files with 128 additions and 105 deletions

View File

@@ -32,6 +32,7 @@
#include "llvm/ADT/Statistic.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/MathExtras.h"
#include "llvm/Support/raw_ostream.h"
#include <algorithm>
@@ -186,8 +187,7 @@ emitGlobal(const GlobalVariable *GV)
switch (GV->getLinkage()) {
case GlobalValue::AppendingLinkage:
cerr << "AppendingLinkage is not supported by this target!\n";
abort();
llvm_report_error("AppendingLinkage is not supported by this target!");
case GlobalValue::LinkOnceAnyLinkage:
case GlobalValue::LinkOnceODRLinkage:
case GlobalValue::WeakAnyLinkage:
@@ -204,14 +204,11 @@ emitGlobal(const GlobalVariable *GV)
case GlobalValue::PrivateLinkage:
break;
case GlobalValue::GhostLinkage:
cerr << "Should not have any unmaterialized functions!\n";
abort();
llvm_report_error("Should not have any unmaterialized functions!");
case GlobalValue::DLLImportLinkage:
cerr << "DLLImport linkage is not supported by this target!\n";
abort();
llvm_report_error("DLLImport linkage is not supported by this target!");
case GlobalValue::DLLExportLinkage:
cerr << "DLLExport linkage is not supported by this target!\n";
abort();
llvm_report_error("DLLExport linkage is not supported by this target!");
default:
assert(0 && "Unknown linkage type!");
}