diff options
author | Zachary Turner <zturner@google.com> | 2017-02-25 00:44:30 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2017-02-25 00:44:30 +0000 |
commit | af299ea5d456aa2fc19d7fdb041a0452d209fd4c (patch) | |
tree | 2d863cba130306041941aeec5b44baa2e9c00ec1 /llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp | |
parent | 42de38076517bc68a2b97c55dcbac7ea8d80b11b (diff) | |
download | llvm-af299ea5d456aa2fc19d7fdb041a0452d209fd4c.zip llvm-af299ea5d456aa2fc19d7fdb041a0452d209fd4c.tar.gz llvm-af299ea5d456aa2fc19d7fdb041a0452d209fd4c.tar.bz2 |
[PDB] General improvements to Stream library.
This adds various new functionality and cleanup surrounding the
use of the Stream library. Major changes include:
* Renaming of all classes for more consistency / meaningfulness
* Addition of some new methods for reading multiple values at once.
* Full suite of unit tests for reader / writer functionality.
* Full set of doxygen comments for all classes.
* Streams now store their own endianness.
* Fixed some bugs in a few of the classes that were discovered
by the unit tests.
llvm-svn: 296215
Diffstat (limited to 'llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp')
-rw-r--r-- | llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp b/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp index 74389f6..2dc14b9 100644 --- a/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp +++ b/llvm/lib/DebugInfo/CodeView/ModuleSubstream.cpp @@ -13,18 +13,16 @@ using namespace llvm; using namespace llvm::codeview; -using namespace llvm::msf; ModuleSubstream::ModuleSubstream() : Kind(ModuleSubstreamKind::None) {} -ModuleSubstream::ModuleSubstream(ModuleSubstreamKind Kind, - ReadableStreamRef Data) +ModuleSubstream::ModuleSubstream(ModuleSubstreamKind Kind, BinaryStreamRef Data) : Kind(Kind), Data(Data) {} -Error ModuleSubstream::initialize(ReadableStreamRef Stream, +Error ModuleSubstream::initialize(BinaryStreamRef Stream, ModuleSubstream &Info) { const ModuleSubsectionHeader *Header; - StreamReader Reader(Stream); + BinaryStreamReader Reader(Stream); if (auto EC = Reader.readObject(Header)) return EC; @@ -42,4 +40,4 @@ uint32_t ModuleSubstream::getRecordLength() const { ModuleSubstreamKind ModuleSubstream::getSubstreamKind() const { return Kind; } -ReadableStreamRef ModuleSubstream::getRecordData() const { return Data; } +BinaryStreamRef ModuleSubstream::getRecordData() const { return Data; } |