[llvm] r206140 - tools: remove duplication of coff_aux_file

Saleem Abdulrasool compnerd at compnerd.org
Sun Apr 13 15:54:15 PDT 2014


Author: compnerd
Date: Sun Apr 13 17:54:15 2014
New Revision: 206140

URL: http://llvm.org/viewvc/llvm-project?rev=206140&view=rev
Log:
tools: remove duplication of coff_aux_file

Now that COFF::coff_aux_file is defined, use that rather than redefining the
type locally.

Modified:
    llvm/trunk/tools/llvm-readobj/COFFDumper.cpp

Modified: llvm/trunk/tools/llvm-readobj/COFFDumper.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-readobj/COFFDumper.cpp?rev=206140&r1=206139&r2=206140&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-readobj/COFFDumper.cpp (original)
+++ llvm/trunk/tools/llvm-readobj/COFFDumper.cpp Sun Apr 13 17:54:15 2014
@@ -428,13 +428,6 @@ static const EnumEntry<unsigned> UnwindO
   { "R15", 15 }
 };
 
-// Some additional COFF structures not defined by llvm::object.
-namespace {
-  struct coff_aux_file_record {
-    char FileName[18];
-  };
-} // namespace
-
 static uint64_t getOffsetOfLSDA(const Win64EH::UnwindInfo& UI) {
   return static_cast<const char*>(UI.getLanguageSpecificData())
          - reinterpret_cast<const char*>(&UI);
@@ -979,13 +972,12 @@ void COFFDumper::printSymbol(const Symbo
       W.printBinary("Unused", makeArrayRef(Aux->Unused));
 
     } else if (Symbol->isFileRecord()) {
-      const coff_aux_file_record *Aux;
+      const coff_aux_file *Aux;
       if (error(getSymbolAuxData(Obj, Symbol + I, Aux)))
         break;
 
       DictScope AS(W, "AuxFileRecord");
       W.printString("FileName", StringRef(Aux->FileName));
-
     } else if (Symbol->isSectionDefinition()) {
       const coff_aux_section_definition *Aux;
       if (error(getSymbolAuxData(Obj, Symbol + I, Aux)))





More information about the llvm-commits mailing list