From 635debe85beb7fbb54590f20b9720d99f938cb84 Mon Sep 17 00:00:00 2001 From: Joerg Sonnenberger Date: Thu, 25 Oct 2012 20:33:17 +0000 Subject: Remove exception handling usage from tblgen. Most places can use PrintFatalError as the unwinding mechanism was not used for anything other than printing the error. The single exception was CodeGenDAGPatterns.cpp, where intermediate errors during type resolution were ignored to simplify incremental platform development. This use is replaced by an error flag in TreePattern and bailout earlier in various places if it is set. llvm-svn: 166712 --- llvm/lib/TableGen/Error.cpp | 8 -------- 1 file changed, 8 deletions(-) (limited to 'llvm/lib/TableGen/Error.cpp') diff --git a/llvm/lib/TableGen/Error.cpp b/llvm/lib/TableGen/Error.cpp index ad98fba9baf..0bb86b0686a 100644 --- a/llvm/lib/TableGen/Error.cpp +++ b/llvm/lib/TableGen/Error.cpp @@ -45,10 +45,6 @@ void PrintWarning(const Twine &Msg) { errs() << "warning:" << Msg << "\n"; } -void PrintWarning(const TGError &Warning) { - PrintWarning(Warning.getLoc(), Warning.getMessage()); -} - void PrintError(ArrayRef ErrorLoc, const Twine &Msg) { PrintMessage(ErrorLoc, SourceMgr::DK_Error, Msg); } @@ -61,10 +57,6 @@ void PrintError(const Twine &Msg) { errs() << "error:" << Msg << "\n"; } -void PrintError(const TGError &Error) { - PrintError(Error.getLoc(), Error.getMessage()); -} - void PrintFatalError(const std::string &Msg) { PrintError(Twine(Msg)); std::exit(1); -- cgit v1.2.3