File indexing completed on 2026-05-10 08:43:44
0001
0002
0003
0004
0005
0006
0007
0008
0009 #ifndef LLVM_DEBUGINFO_PDB_NATIVE_INJECTEDSOURCESTREAM_H
0010 #define LLVM_DEBUGINFO_PDB_NATIVE_INJECTEDSOURCESTREAM_H
0011
0012 #include "llvm/DebugInfo/MSF/MappedBlockStream.h"
0013 #include "llvm/DebugInfo/PDB/Native/HashTable.h"
0014 #include "llvm/Support/Error.h"
0015
0016 namespace llvm {
0017 namespace pdb {
0018 struct SrcHeaderBlockEntry;
0019 struct SrcHeaderBlockHeader;
0020 class PDBStringTable;
0021
0022 class InjectedSourceStream {
0023 public:
0024 InjectedSourceStream(std::unique_ptr<msf::MappedBlockStream> Stream);
0025 Error reload(const PDBStringTable &Strings);
0026
0027 using const_iterator = HashTable<SrcHeaderBlockEntry>::const_iterator;
0028 const_iterator begin() const { return InjectedSourceTable.begin(); }
0029 const_iterator end() const { return InjectedSourceTable.end(); }
0030
0031 uint32_t size() const { return InjectedSourceTable.size(); }
0032
0033 private:
0034 std::unique_ptr<msf::MappedBlockStream> Stream;
0035
0036 const SrcHeaderBlockHeader* Header;
0037 HashTable<SrcHeaderBlockEntry> InjectedSourceTable;
0038 };
0039 }
0040 }
0041
0042 #endif