X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FObject%2FMachOObject.h;h=a7bf6eb7d85d448390917fcf7b5f0dd5d3818d2c;hb=9942acab0a42755637a682308c8262b88cbbb9e9;hp=03d9c147b413a7316f2859bbea9da31bb8004360;hpb=71130f8aa1cef096083b95267a8a688a3bef6426;p=oota-llvm.git diff --git a/include/llvm/Object/MachOObject.h b/include/llvm/Object/MachOObject.h index 03d9c147b41..a7bf6eb7d85 100644 --- a/include/llvm/Object/MachOObject.h +++ b/include/llvm/Object/MachOObject.h @@ -19,6 +19,7 @@ namespace llvm { class MemoryBuffer; +class raw_ostream; namespace object { @@ -149,6 +150,9 @@ public: void ReadDysymtabLoadCommand( const LoadCommandInfo &LCI, InMemoryStruct &Res) const; + void ReadLinkeditDataLoadCommand( + const LoadCommandInfo &LCI, + InMemoryStruct &Res) const; void ReadIndirectSymbolTableEntry( const macho::DysymtabLoadCommand &DLC, unsigned Index, @@ -172,7 +176,26 @@ public: InMemoryStruct &Res) const; /// @} + + /// @name Object Dump Facilities + /// @{ + /// dump - Support for debugging, callable in GDB: V->dump() + // + void dump() const; + void dumpHeader() const; + + /// print - Implement operator<< on Value. + /// + void print(raw_ostream &O) const; + void printHeader(raw_ostream &O) const; + + /// @} }; + +inline raw_ostream &operator<<(raw_ostream &OS, const MachOObject &V) { + V.print(OS); + return OS; +} } // end namespace object } // end namespace llvm