NativeEnumInjectedSources.h 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #pragma once
  2. #ifdef __GNUC__
  3. #pragma GCC diagnostic push
  4. #pragma GCC diagnostic ignored "-Wunused-parameter"
  5. #endif
  6. //==- NativeEnumInjectedSources.cpp - Native Injected Source Enumerator --*-==//
  7. //
  8. // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
  9. // See https://llvm.org/LICENSE.txt for license information.
  10. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  11. //
  12. //===----------------------------------------------------------------------===//
  13. #ifndef LLVM_DEBUGINFO_PDB_NATIVE_NATIVEENUMINJECTEDSOURCES_H
  14. #define LLVM_DEBUGINFO_PDB_NATIVE_NATIVEENUMINJECTEDSOURCES_H
  15. #include "llvm/DebugInfo/PDB/IPDBEnumChildren.h"
  16. #include "llvm/DebugInfo/PDB/IPDBInjectedSource.h"
  17. #include "llvm/DebugInfo/PDB/Native/InjectedSourceStream.h"
  18. namespace llvm {
  19. namespace pdb {
  20. class InjectedSourceStream;
  21. class PDBFile;
  22. class PDBStringTable;
  23. class NativeEnumInjectedSources : public IPDBEnumChildren<IPDBInjectedSource> {
  24. public:
  25. NativeEnumInjectedSources(PDBFile &File, const InjectedSourceStream &IJS,
  26. const PDBStringTable &Strings);
  27. uint32_t getChildCount() const override;
  28. std::unique_ptr<IPDBInjectedSource>
  29. getChildAtIndex(uint32_t Index) const override;
  30. std::unique_ptr<IPDBInjectedSource> getNext() override;
  31. void reset() override;
  32. private:
  33. PDBFile &File;
  34. const InjectedSourceStream &Stream;
  35. const PDBStringTable &Strings;
  36. InjectedSourceStream::const_iterator Cur;
  37. };
  38. } // namespace pdb
  39. } // namespace llvm
  40. #endif
  41. #ifdef __GNUC__
  42. #pragma GCC diagnostic pop
  43. #endif