diff options
| author | Reid Kleckner <reid@kleckner.net> | 2013-08-06 22:51:21 +0000 |
|---|---|---|
| committer | Reid Kleckner <reid@kleckner.net> | 2013-08-06 22:51:21 +0000 |
| commit | d78273f4fdce247ab52cb26ed0d1f908efb44f39 (patch) | |
| tree | 23740d6e8113b11c35a3ea4f3ad42e37c51afbed /llvm/lib/TableGen/TGParser.cpp | |
| parent | a7cd6bf3bbf9d1efc2ec7b9c617209408caf6a86 (diff) | |
| download | bcm5719-llvm-d78273f4fdce247ab52cb26ed0d1f908efb44f39.tar.gz bcm5719-llvm-d78273f4fdce247ab52cb26ed0d1f908efb44f39.zip | |
Remove some std stream usage from Support and TableGen
LLVM's coding standards recommend raw_ostream and MemoryBuffer for
reading and writing text.
This has the side effect of allowing clang to compile more of Support
and TableGen in the Microsoft C++ ABI.
llvm-svn: 187826
Diffstat (limited to 'llvm/lib/TableGen/TGParser.cpp')
| -rw-r--r-- | llvm/lib/TableGen/TGParser.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/llvm/lib/TableGen/TGParser.cpp b/llvm/lib/TableGen/TGParser.cpp index 86ad2a6e3c0..965cd00396e 100644 --- a/llvm/lib/TableGen/TGParser.cpp +++ b/llvm/lib/TableGen/TGParser.cpp @@ -1271,10 +1271,11 @@ Init *TGParser::ParseSimpleValue(Record *CurRec, RecTy *ItemType, if (ItemType != 0) { ListRecTy *ListType = dyn_cast<ListRecTy>(ItemType); if (ListType == 0) { - std::stringstream s; - s << "Type mismatch for list, expected list type, got " - << ItemType->getAsString(); - TokError(s.str()); + std::string s; + raw_string_ostream ss(s); + ss << "Type mismatch for list, expected list type, got " + << ItemType->getAsString(); + TokError(ss.str()); return 0; } GivenListTy = ListType; |

