[PATCH] Refactor parseFile API to use LinkerInput directly
    Michael Spencer 
    bigcheesegs at gmail.com
       
    Wed Sep  4 13:18:14 PDT 2013
    
    
  
  LinkerInput was never designed to be sub-classed. The original intent was to provide a way to make sure a file was only mapped once, but it didn't really provide that.
  Whatever does get passed to Reader needs to either be part of the ReaderWriter lib or Core, so I think that this change is fine if it also moved LinkerInput to Core.
================
Comment at: include/lld/Driver/LinkerInput.h:96
@@ -98,2 +95,3 @@
 private:
   mutable std::unique_ptr<llvm::MemoryBuffer> _buffer;
+  std::string _userPath;
----------------
No longer needs to be mutable.
================
Comment at: lib/ReaderWriter/ReaderArchive.cpp:125
@@ -124,2 +124,3 @@
 private:
+  LinkerInput                               input;
   std::unique_ptr<llvm::object::Archive>    _archive;
----------------
_input.
http://llvm-reviews.chandlerc.com/D1598
    
    
More information about the llvm-commits
mailing list