diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2010-09-27 17:42:11 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2010-09-27 17:42:11 +0000 |
commit | c758311025805d901b11695aa04148f2da3f307f (patch) | |
tree | 432f0f802e6154a89baab92a4588b7ee4420d43d /llvm/utils/TableGen/TGParser.h | |
parent | 23cb3716df6c15a895a3aa690f21db903cd0b9bd (diff) | |
download | bcm5719-llvm-c758311025805d901b11695aa04148f2da3f307f.tar.gz bcm5719-llvm-c758311025805d901b11695aa04148f2da3f307f.zip |
Push twines deeper into SourceMgr's error handling methods.
llvm-svn: 114847
Diffstat (limited to 'llvm/utils/TableGen/TGParser.h')
-rw-r--r-- | llvm/utils/TableGen/TGParser.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/utils/TableGen/TGParser.h b/llvm/utils/TableGen/TGParser.h index 0aee931423a..6e165220a07 100644 --- a/llvm/utils/TableGen/TGParser.h +++ b/llvm/utils/TableGen/TGParser.h @@ -15,6 +15,7 @@ #define TGPARSER_H #include "TGLexer.h" +#include "llvm/ADT/Twine.h" #include "llvm/Support/SourceMgr.h" #include <map> @@ -53,11 +54,11 @@ public: /// routines return true on error, or false on success. bool ParseFile(); - bool Error(SMLoc L, const std::string &Msg) const { + bool Error(SMLoc L, const Twine &Msg) const { Lex.PrintError(L, Msg); return true; } - bool TokError(const std::string &Msg) const { + bool TokError(const Twine &Msg) const { return Error(Lex.getLoc(), Msg); } private: // Semantic analysis methods. |