diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-09-06 18:36:24 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-09-06 18:36:24 +0000 |
commit | 36c5ade2f4674b544039d78db4c466756cf142b0 (patch) | |
tree | 3d3ed1e1987dbe6444294b1b4e249814b97b97a5 /include/clang/CodeGen/ObjectFilePCHContainerOperations.h | |
parent | 51ece4aae5857052d224ce52277924c74685714e (diff) |
Notes
Diffstat (limited to 'include/clang/CodeGen/ObjectFilePCHContainerOperations.h')
-rw-r--r-- | include/clang/CodeGen/ObjectFilePCHContainerOperations.h | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/include/clang/CodeGen/ObjectFilePCHContainerOperations.h b/include/clang/CodeGen/ObjectFilePCHContainerOperations.h index 4540efb29781..e82aab787515 100644 --- a/include/clang/CodeGen/ObjectFilePCHContainerOperations.h +++ b/include/clang/CodeGen/ObjectFilePCHContainerOperations.h @@ -14,30 +14,32 @@ namespace clang { -/// \brief A PCHContainerOperations implementation that uses LLVM to +/// A PCHContainerWriter implementation that uses LLVM to /// wraps Clang modules inside a COFF, ELF, or Mach-O container. -class ObjectFilePCHContainerOperations - : public PCHContainerOperations { - /// \brief Return an ASTConsumer that can be chained with a +class ObjectFilePCHContainerWriter : public PCHContainerWriter { + StringRef getFormat() const override { return "obj"; } + + /// Return an ASTConsumer that can be chained with a /// PCHGenerator that produces a wrapper file format /// that also contains full debug info for the module. - std::unique_ptr<ASTConsumer> - CreatePCHContainerGenerator( + std::unique_ptr<ASTConsumer> CreatePCHContainerGenerator( DiagnosticsEngine &Diags, const HeaderSearchOptions &HSO, const PreprocessorOptions &PPO, const TargetOptions &TO, const LangOptions &LO, const std::string &MainFileName, const std::string &OutputFileName, llvm::raw_pwrite_stream *OS, std::shared_ptr<PCHBuffer> Buffer) const override; +}; + +/// A PCHContainerReader implementation that uses LLVM to +/// wraps Clang modules inside a COFF, ELF, or Mach-O container. +class ObjectFilePCHContainerReader : public PCHContainerReader { + StringRef getFormat() const override { return "obj"; } - /// \brief Initialize an llvm::BitstreamReader with the serialized + /// Initialize an llvm::BitstreamReader with the serialized /// AST inside the PCH container Buffer. void ExtractPCH(llvm::MemoryBufferRef Buffer, llvm::BitstreamReader &StreamFile) const override; - - }; - } - #endif |