diff options
author | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-11-23 23:16:32 +0000 |
---|---|---|
committer | Eugene Zelenko <eugene.zelenko@gmail.com> | 2016-11-23 23:16:32 +0000 |
commit | 570e39a25ca345e3facaea16b2facefddfb3aa92 (patch) | |
tree | 04b12c1516d05fbbcd6883f4579a9a62eb8d45be /llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp | |
parent | bf9523f549cc28c9c9836fa9442db86ba4657433 (diff) | |
download | bcm5719-llvm-570e39a25ca345e3facaea16b2facefddfb3aa92.tar.gz bcm5719-llvm-570e39a25ca345e3facaea16b2facefddfb3aa92.zip |
[DebugInfo] Fix some Clang-tidy modernize-use-default and Include What You Use warnings; other minor fixes (NFC).
Per Zachary Turner and Mehdi Amini suggestion to make only post-commit reviews.
llvm-svn: 287838
Diffstat (limited to 'llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp')
-rw-r--r-- | llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp b/llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp index f7bb8ab58a0..b429d21b4b9 100644 --- a/llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp +++ b/llvm/lib/DebugInfo/PDB/Raw/PDBFile.cpp @@ -7,24 +7,27 @@ // //===----------------------------------------------------------------------===// -#include "llvm/DebugInfo/PDB/Raw/PDBFile.h" - #include "llvm/ADT/ArrayRef.h" +#include "llvm/ADT/STLExtras.h" +#include "llvm/DebugInfo/MSF/MappedBlockStream.h" +#include "llvm/DebugInfo/MSF/MSFCommon.h" #include "llvm/DebugInfo/MSF/StreamArray.h" #include "llvm/DebugInfo/MSF/StreamInterface.h" #include "llvm/DebugInfo/MSF/StreamReader.h" -#include "llvm/DebugInfo/MSF/StreamWriter.h" #include "llvm/DebugInfo/PDB/Raw/DbiStream.h" #include "llvm/DebugInfo/PDB/Raw/GlobalsStream.h" #include "llvm/DebugInfo/PDB/Raw/InfoStream.h" #include "llvm/DebugInfo/PDB/Raw/NameHashTable.h" +#include "llvm/DebugInfo/PDB/Raw/PDBFile.h" #include "llvm/DebugInfo/PDB/Raw/PublicsStream.h" #include "llvm/DebugInfo/PDB/Raw/RawError.h" #include "llvm/DebugInfo/PDB/Raw/SymbolStream.h" #include "llvm/DebugInfo/PDB/Raw/TpiStream.h" #include "llvm/Support/Endian.h" -#include "llvm/Support/FileOutputBuffer.h" -#include "llvm/Support/MemoryBuffer.h" +#include "llvm/Support/Error.h" +#include <algorithm> +#include <cassert> +#include <cstdint> using namespace llvm; using namespace llvm::codeview; @@ -33,13 +36,13 @@ using namespace llvm::pdb; namespace { typedef FixedStreamArray<support::ulittle32_t> ulittle_array; -} +} // end anonymous namespace PDBFile::PDBFile(std::unique_ptr<ReadableStream> PdbFileBuffer, BumpPtrAllocator &Allocator) : Allocator(Allocator), Buffer(std::move(PdbFileBuffer)) {} -PDBFile::~PDBFile() {} +PDBFile::~PDBFile() = default; uint32_t PDBFile::getBlockSize() const { return ContainerLayout.SB->BlockSize; } @@ -214,7 +217,7 @@ Error PDBFile::parseStreamData() { return Error::success(); } -llvm::ArrayRef<support::ulittle32_t> PDBFile::getDirectoryBlockArray() const { +ArrayRef<support::ulittle32_t> PDBFile::getDirectoryBlockArray() const { return ContainerLayout.DirectoryBlocks; } |