[lld] r194037 - Remove unnecessary namespace qualifier.

Rui Ueyama ruiu at google.com
Mon Nov 4 17:37:41 PST 2013


Author: ruiu
Date: Mon Nov  4 19:37:40 2013
New Revision: 194037

URL: http://llvm.org/viewvc/llvm-project?rev=194037&view=rev
Log:
Remove unnecessary namespace qualifier.

Modified:
    lld/trunk/include/lld/Driver/CoreInputGraph.h
    lld/trunk/include/lld/Driver/DarwinInputGraph.h
    lld/trunk/include/lld/Driver/GnuLdInputGraph.h
    lld/trunk/include/lld/Driver/InputGraph.h
    lld/trunk/include/lld/Driver/WinLinkInputGraph.h
    lld/trunk/include/lld/ReaderWriter/ELFLinkingContext.h
    lld/trunk/include/lld/ReaderWriter/LinkerScript.h
    lld/trunk/include/lld/ReaderWriter/ReaderLinkerScript.h
    lld/trunk/lib/Core/PassManager.cpp
    lld/trunk/lib/Driver/Driver.cpp
    lld/trunk/lib/Driver/GnuLdDriver.cpp
    lld/trunk/lib/Driver/InputGraph.cpp
    lld/trunk/lib/Passes/LayoutPass.cpp
    lld/trunk/lib/Passes/RoundTripNativePass.cpp
    lld/trunk/lib/Passes/RoundTripYAMLPass.cpp
    lld/trunk/lib/ReaderWriter/ELF/Atoms.h
    lld/trunk/lib/ReaderWriter/ELF/ELFLinkingContext.cpp
    lld/trunk/lib/ReaderWriter/ELF/File.h
    lld/trunk/lib/ReaderWriter/ELF/Reader.cpp
    lld/trunk/lib/ReaderWriter/ELF/SectionChunks.h
    lld/trunk/lib/ReaderWriter/ELF/SegmentChunks.h
    lld/trunk/lib/ReaderWriter/LinkerScript.cpp
    lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFile.h
    lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp
    lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp
    lld/trunk/lib/ReaderWriter/PECOFF/ReaderCOFF.cpp
    lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.cpp
    lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.h
    lld/trunk/lib/ReaderWriter/ReaderLinkerScript.cpp
    lld/trunk/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp

Modified: lld/trunk/include/lld/Driver/CoreInputGraph.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Driver/CoreInputGraph.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/Driver/CoreInputGraph.h (original)
+++ lld/trunk/include/lld/Driver/CoreInputGraph.h Mon Nov  4 19:37:40 2013
@@ -48,8 +48,8 @@ public:
       return make_error_code(llvm::errc::no_such_file_or_directory);
 
     // Create a memory buffer
-    OwningPtr<llvm::MemoryBuffer> opmb;
-    if (error_code ec = llvm::MemoryBuffer::getFileOrSTDIN(*filePath, opmb))
+    OwningPtr<MemoryBuffer> opmb;
+    if (error_code ec = MemoryBuffer::getFileOrSTDIN(*filePath, opmb))
       return ec;
 
     std::unique_ptr<MemoryBuffer> mb(opmb.take());

Modified: lld/trunk/include/lld/Driver/DarwinInputGraph.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Driver/DarwinInputGraph.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/Driver/DarwinInputGraph.h (original)
+++ lld/trunk/include/lld/Driver/DarwinInputGraph.h Mon Nov  4 19:37:40 2013
@@ -41,13 +41,13 @@ public:
   }
 
   /// \brief Parse the input file to lld::File.
-  llvm::error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
+  error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
     // Read the file to _buffer.
     bool isYaml = false;
     if (error_code ec = readFile(ctx, diagnostics, isYaml))
       return ec;
     (void) (_isWholeArchive);
-    return llvm::error_code::success();
+    return error_code::success();
   }
 
   /// \brief Return the file that has to be processed by the resolver

Modified: lld/trunk/include/lld/Driver/GnuLdInputGraph.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Driver/GnuLdInputGraph.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/Driver/GnuLdInputGraph.h (original)
+++ lld/trunk/include/lld/Driver/GnuLdInputGraph.h Mon Nov  4 19:37:40 2013
@@ -48,7 +48,7 @@ public:
   virtual bool validate() { return true; }
 
   /// \brief create an error string for printing purposes
-  virtual std::string errStr(llvm::error_code);
+  virtual std::string errStr(error_code);
 
   /// \brief Dump the Input Element
   virtual bool dump(raw_ostream &diagnostics) {
@@ -71,7 +71,7 @@ public:
   }
 
   /// \brief Parse the input file to lld::File.
-  llvm::error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
+  error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
     // Read the file to _buffer.
     bool isYaml = false;
     if (error_code ec = readFile(ctx, diagnostics, isYaml))
@@ -162,10 +162,10 @@ public:
   }
 
   /// \brief Dump the ELFGroup
-  virtual bool dump(llvm::raw_ostream &) { return true; }
+  virtual bool dump(raw_ostream &) { return true; }
 
   /// \brief Parse the group members.
-  llvm::error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
+  error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
     for (auto &ei : _elements)
       if (error_code ec = ei->parse(ctx, diagnostics))
         return ec;

Modified: lld/trunk/include/lld/Driver/InputGraph.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Driver/InputGraph.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/Driver/InputGraph.h (original)
+++ lld/trunk/include/lld/Driver/InputGraph.h Mon Nov  4 19:37:40 2013
@@ -159,7 +159,7 @@ public:
   virtual bool dump(raw_ostream &diagnostics) = 0;
 
   /// \brief parse the input element
-  virtual llvm::error_code parse(const LinkingContext &, raw_ostream &) = 0;
+  virtual error_code parse(const LinkingContext &, raw_ostream &) = 0;
 
   /// \brief functions for the resolver to use
 
@@ -263,20 +263,20 @@ public:
   }
 
   /// \brief create an error string for printing purposes
-  virtual std::string errStr(llvm::error_code errc) {
+  virtual std::string errStr(error_code errc) {
     std::string msg = errc.message();
     Twine twine = Twine("Cannot open ") + _path + ": " + msg;
     return twine.str();
   }
 
   /// \brief Memory buffer pointed by the file.
-  llvm::MemoryBuffer &getBuffer() const {
+  MemoryBuffer &getBuffer() const {
     assert(_buffer);
     return *_buffer;
   }
 
   /// \brief Return the memory buffer and transfer ownership.
-  std::unique_ptr<llvm::MemoryBuffer> takeBuffer() {
+  std::unique_ptr<MemoryBuffer> takeBuffer() {
     assert(_buffer);
     return std::move(_buffer);
   }
@@ -314,7 +314,7 @@ protected:
 
   StringRef _path;                             // The path of the Input file
   InputGraph::FileVectorT _files;              // A vector of lld File objects
-  std::unique_ptr<llvm::MemoryBuffer> _buffer; // Memory buffer to actual
+  std::unique_ptr<MemoryBuffer> _buffer; // Memory buffer to actual
                                                // contents
   uint32_t _resolveState;                      // The resolve state of the file
   uint32_t _nextFileIndex; // The next file that would be processed by the
@@ -348,7 +348,7 @@ class SimpleFileNode : public InputEleme
 public:
   SimpleFileNode(StringRef path, int64_t ordinal = -1);
 
-  virtual llvm::ErrorOr<StringRef> path(const LinkingContext &) const {
+  virtual ErrorOr<StringRef> path(const LinkingContext &) const {
     return _path;
   }
 
@@ -389,7 +389,7 @@ public:
   virtual bool dump(raw_ostream &) { return true; }
 
   /// \brief parse the input element
-  virtual llvm::error_code parse(const LinkingContext &, raw_ostream &) {
+  virtual error_code parse(const LinkingContext &, raw_ostream &) {
     return error_code::success();
   }
 

Modified: lld/trunk/include/lld/Driver/WinLinkInputGraph.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Driver/WinLinkInputGraph.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/Driver/WinLinkInputGraph.h (original)
+++ lld/trunk/include/lld/Driver/WinLinkInputGraph.h Mon Nov  4 19:37:40 2013
@@ -35,7 +35,7 @@ public:
     return a->kind() == InputElement::Kind::File;
   }
 
-  virtual llvm::ErrorOr<StringRef> getPath(const LinkingContext &ctx) const;
+  virtual ErrorOr<StringRef> getPath(const LinkingContext &ctx) const;
 
   /// \brief Parse the input file to lld::File.
   error_code parse(const LinkingContext &ctx, raw_ostream &diagnostics) {
@@ -87,7 +87,7 @@ public:
   PECOFFLibraryNode(PECOFFLinkingContext &ctx, StringRef path)
       : PECOFFFileNode(ctx, path) {}
 
-  virtual llvm::ErrorOr<StringRef> getPath(const LinkingContext &ctx) const;
+  virtual ErrorOr<StringRef> getPath(const LinkingContext &ctx) const;
 };
 
 } // namespace lld

Modified: lld/trunk/include/lld/ReaderWriter/ELFLinkingContext.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/ReaderWriter/ELFLinkingContext.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/ReaderWriter/ELFLinkingContext.h (original)
+++ lld/trunk/include/lld/ReaderWriter/ELFLinkingContext.h Mon Nov  4 19:37:40 2013
@@ -156,7 +156,7 @@ public:
   virtual void setNoAllowDynamicLibraries() { _noAllowDynamicLibraries = true; }
 
   /// Searches directories for a match on the input File
-  llvm::ErrorOr<StringRef>
+  ErrorOr<StringRef>
   searchLibrary(StringRef libName,
                 const std::vector<StringRef> &searchPath) const;
 

Modified: lld/trunk/include/lld/ReaderWriter/LinkerScript.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/ReaderWriter/LinkerScript.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/ReaderWriter/LinkerScript.h (original)
+++ lld/trunk/include/lld/ReaderWriter/LinkerScript.h Mon Nov  4 19:37:40 2013
@@ -44,7 +44,7 @@ public:
   Token() : _kind(unknown) {}
   Token(StringRef range, Kind kind) : _range(range), _kind(kind) {}
 
-  void dump(llvm::raw_ostream &os) const;
+  void dump(raw_ostream &os) const;
 
   StringRef _range;
   Kind _kind;
@@ -52,7 +52,7 @@ public:
 
 class Lexer {
 public:
-  explicit Lexer(std::unique_ptr<llvm::MemoryBuffer> mb)
+  explicit Lexer(std::unique_ptr<MemoryBuffer> mb)
       : _buffer(mb->getBuffer()) {
     _sourceManager.AddNewSourceBuffer(mb.release(), llvm::SMLoc());
   }
@@ -83,7 +83,7 @@ public:
 
   Kind getKind() const { return _kind; }
 
-  virtual void dump(llvm::raw_ostream &os) const = 0;
+  virtual void dump(raw_ostream &os) const = 0;
 
   virtual ~Command() {}
 
@@ -103,7 +103,7 @@ public:
     return c->getKind() == Kind::OutputFormat;
   }
 
-  virtual void dump(llvm::raw_ostream &os) const {
+  virtual void dump(raw_ostream &os) const {
     os << "OUTPUT_FORMAT(" << getFormat() << ")\n";
   }
 
@@ -133,7 +133,7 @@ public:
 
   static bool classof(const Command *c) { return c->getKind() == Kind::Group; }
 
-  virtual void dump(llvm::raw_ostream &os) const {
+  virtual void dump(raw_ostream &os) const {
     os << "GROUP(";
     bool first = true;
     for (const auto &path : getPaths()) {
@@ -165,7 +165,7 @@ public:
     return c->getKind() == Kind::Entry;
   }
 
-  virtual void dump(llvm::raw_ostream &os) const {
+  virtual void dump(raw_ostream &os) const {
     os << "ENTRY(" << _entryName << ")\n";
   }
 
@@ -179,7 +179,7 @@ private:
 
 class LinkerScript {
 public:
-  void dump(llvm::raw_ostream &os) const {
+  void dump(raw_ostream &os) const {
     for (const auto &c : _commands)
       c->dump(os);
   }

Modified: lld/trunk/include/lld/ReaderWriter/ReaderLinkerScript.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/ReaderWriter/ReaderLinkerScript.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/include/lld/ReaderWriter/ReaderLinkerScript.h (original)
+++ lld/trunk/include/lld/ReaderWriter/ReaderLinkerScript.h Mon Nov  4 19:37:40 2013
@@ -25,7 +25,7 @@ public:
 
   /// \brief Returns a vector of Files that are contained in the archive file
   ///        pointed to by the Memorybuffer
-  error_code parseFile(std::unique_ptr<llvm::MemoryBuffer> &mb,
+  error_code parseFile(std::unique_ptr<MemoryBuffer> &mb,
                        std::vector<std::unique_ptr<File> > &result) const;
 };
 

Modified: lld/trunk/lib/Core/PassManager.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Core/PassManager.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Core/PassManager.cpp (original)
+++ lld/trunk/lib/Core/PassManager.cpp Mon Nov  4 19:37:40 2013
@@ -19,6 +19,6 @@ error_code PassManager::runOnFile(std::u
   for (auto &pass : _passes) {
     pass->perform(mf);
   }
-  return llvm::error_code::success();
+  return error_code::success();
 }
 } // end namespace lld

Modified: lld/trunk/lib/Driver/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Driver/Driver.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Driver/Driver.cpp (original)
+++ lld/trunk/lib/Driver/Driver.cpp Mon Nov  4 19:37:40 2013
@@ -62,7 +62,7 @@ bool Driver::link(LinkingContext &contex
       llvm::raw_string_ostream stream(buf);
 
       if (error_code ec = ie->parse(context, stream)) {
-        FileNode *fileNode = llvm::dyn_cast<FileNode>(ie.get());
+        FileNode *fileNode = dyn_cast<FileNode>(ie.get());
         stream << fileNode->errStr(ec) << "\n";
         fail = true;
       }

Modified: lld/trunk/lib/Driver/GnuLdDriver.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Driver/GnuLdDriver.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Driver/GnuLdDriver.cpp (original)
+++ lld/trunk/lib/Driver/GnuLdDriver.cpp Mon Nov  4 19:37:40 2013
@@ -75,7 +75,7 @@ llvm::ErrorOr<StringRef> ELFFileNode::ge
   return _elfLinkingContext.searchLibrary(_path, _libraryPaths);
 }
 
-std::string ELFFileNode::errStr(llvm::error_code errc) {
+std::string ELFFileNode::errStr(error_code errc) {
   if (errc == llvm::errc::no_such_file_or_directory) {
     if (_isDashlPrefix)
       return (Twine("Unable to find library -l") + _path).str();
@@ -256,14 +256,14 @@ bool GnuLdDriver::parse(int argc, const
     case OPT_start_group: {
       std::unique_ptr<InputElement> controlStart(new ELFGroup(*ctx, index++));
       controlNodeStack.push(controlStart.get());
-      (llvm::dyn_cast<ControlNode>)(controlNodeStack.top())
+      (dyn_cast<ControlNode>)(controlNodeStack.top())
           ->processControlEnter();
       inputGraph->addInputElement(std::move(controlStart));
       break;
     }
 
     case OPT_end_group:
-      (llvm::dyn_cast<ControlNode>)(controlNodeStack.top())
+      (dyn_cast<ControlNode>)(controlNodeStack.top())
           ->processControlExit();
       controlNodeStack.pop();
       break;
@@ -276,7 +276,7 @@ bool GnuLdDriver::parse(int argc, const
       if (controlNodeStack.empty())
         inputGraph->addInputElement(std::move(inputFile));
       else
-        (llvm::dyn_cast<ControlNode>)(controlNodeStack.top())
+        (dyn_cast<ControlNode>)(controlNodeStack.top())
             ->processInputElement(std::move(inputFile));
       break;
     }

Modified: lld/trunk/lib/Driver/InputGraph.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Driver/InputGraph.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Driver/InputGraph.cpp (original)
+++ lld/trunk/lib/Driver/InputGraph.cpp Mon Nov  4 19:37:40 2013
@@ -107,9 +107,9 @@ FileNode::readFile(const LinkingContext
     return make_error_code(llvm::errc::no_such_file_or_directory);
 
   // Create a memory buffer
-  OwningPtr<llvm::MemoryBuffer> opmb;
+  OwningPtr<MemoryBuffer> opmb;
 
-  if (error_code ec = llvm::MemoryBuffer::getFileOrSTDIN(*filePath, opmb))
+  if (error_code ec = MemoryBuffer::getFileOrSTDIN(*filePath, opmb))
     return ec;
 
   std::unique_ptr<MemoryBuffer> mb(opmb.take());

Modified: lld/trunk/lib/Passes/LayoutPass.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Passes/LayoutPass.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Passes/LayoutPass.cpp (original)
+++ lld/trunk/lib/Passes/LayoutPass.cpp Mon Nov  4 19:37:40 2013
@@ -223,7 +223,7 @@ void LayoutPass::buildFollowOnTable(Muta
     for (const Reference *r : *ai) {
       if (r->kind() != lld::Reference::kindLayoutAfter)
         continue;
-      const DefinedAtom *targetAtom = llvm::dyn_cast<DefinedAtom>(r->target());
+      const DefinedAtom *targetAtom = dyn_cast<DefinedAtom>(r->target());
       _followOnNexts[ai] = targetAtom;
 
       // If we find a followon for the first time, lets make that atom as the
@@ -283,7 +283,7 @@ void LayoutPass::buildInGroupTable(Mutab
   for (const DefinedAtom *ai : range) {
     for (const Reference *r : *ai) {
       if (r->kind() == lld::Reference::kindInGroup) {
-        const DefinedAtom *rootAtom = llvm::dyn_cast<DefinedAtom>(r->target());
+        const DefinedAtom *rootAtom = dyn_cast<DefinedAtom>(r->target());
         // If the root atom is not part of any root
         // create a new root
         if (_followOnRoots.count(rootAtom) == 0) {
@@ -355,7 +355,7 @@ void LayoutPass::buildPrecededByTable(Mu
   for (const DefinedAtom *ai : range) {
     for (const Reference *r : *ai) {
       if (r->kind() == lld::Reference::kindLayoutBefore) {
-        const DefinedAtom *targetAtom = llvm::dyn_cast<DefinedAtom>(r->target());
+        const DefinedAtom *targetAtom = dyn_cast<DefinedAtom>(r->target());
         // Is the targetAtom not chained
         if (_followOnRoots.count(targetAtom) == 0) {
           // Is the current atom not part of any root ?
@@ -428,7 +428,7 @@ namespace {
 typedef llvm::DenseMap<const DefinedAtom *, const DefinedAtom *> AtomToAtomT;
 
 std::string atomToDebugString(const Atom *atom) {
-  const DefinedAtom *definedAtom = llvm::dyn_cast<DefinedAtom>(atom);
+  const DefinedAtom *definedAtom = dyn_cast<DefinedAtom>(atom);
   std::string str;
   llvm::raw_string_ostream s(str);
   if (definedAtom->name().empty())

Modified: lld/trunk/lib/Passes/RoundTripNativePass.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Passes/RoundTripNativePass.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Passes/RoundTripNativePass.cpp (original)
+++ lld/trunk/lib/Passes/RoundTripNativePass.cpp Mon Nov  4 19:37:40 2013
@@ -31,8 +31,8 @@ void RoundTripNativePass::perform(std::u
   // The file that is written would be kept around if there is a problem
   // writing to the file or when reading atoms back from the file.
   nativeWriter->writeFile(*mergedFile, tmpNativeFile.str());
-  llvm::OwningPtr<llvm::MemoryBuffer> buff;
-  if (llvm::MemoryBuffer::getFileOrSTDIN(tmpNativeFile.str(), buff))
+  OwningPtr<MemoryBuffer> buff;
+  if (MemoryBuffer::getFileOrSTDIN(tmpNativeFile.str(), buff))
     return;
 
   std::unique_ptr<MemoryBuffer> mb(buff.take());

Modified: lld/trunk/lib/Passes/RoundTripYAMLPass.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Passes/RoundTripYAMLPass.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/Passes/RoundTripYAMLPass.cpp (original)
+++ lld/trunk/lib/Passes/RoundTripYAMLPass.cpp Mon Nov  4 19:37:40 2013
@@ -30,8 +30,8 @@ void RoundTripYAMLPass::perform(std::uni
   // The file that is written would be kept around if there is a problem
   // writing to the file or when reading atoms back from the file.
   yamlWriter->writeFile(*mergedFile, tmpYAMLFile.str());
-  llvm::OwningPtr<llvm::MemoryBuffer> buff;
-  if (llvm::MemoryBuffer::getFileOrSTDIN(tmpYAMLFile.str(), buff))
+  OwningPtr<MemoryBuffer> buff;
+  if (MemoryBuffer::getFileOrSTDIN(tmpYAMLFile.str(), buff))
     return;
 
   std::unique_ptr<MemoryBuffer> mb(buff.take());

Modified: lld/trunk/lib/ReaderWriter/ELF/Atoms.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/Atoms.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/Atoms.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/Atoms.h Mon Nov  4 19:37:40 2013
@@ -170,7 +170,7 @@ public:
                  StringRef sectionName,
                  const Elf_Sym *symbol,
                  const Elf_Shdr *section,
-                 llvm::ArrayRef<uint8_t> contentData,
+                 ArrayRef<uint8_t> contentData,
                  unsigned int referenceStart,
                  unsigned int referenceEnd,
                  std::vector<ELFReference<ELFT>*> &referenceList)
@@ -482,7 +482,7 @@ public:
     return false;
   }
 
-  virtual llvm::ArrayRef<uint8_t> rawContent() const {
+  virtual ArrayRef<uint8_t> rawContent() const {
     return _contentData;
   }
 
@@ -525,7 +525,7 @@ private:
   const Elf_Sym *_symbol;
   const Elf_Shdr *_section;
   /// \brief Holds the bits that make up the atom.
-  llvm::ArrayRef<uint8_t> _contentData;
+  ArrayRef<uint8_t> _contentData;
 
   uint64_t _ordinal;
   unsigned int _referenceStartIndex;
@@ -543,7 +543,7 @@ template <class ELFT> class ELFMergeAtom
 
 public:
   ELFMergeAtom(const ELFFile<ELFT> &file, StringRef sectionName,
-               const Elf_Shdr *section, llvm::ArrayRef<uint8_t> contentData,
+               const Elf_Shdr *section, ArrayRef<uint8_t> contentData,
                uint64_t offset)
       : _owningFile(file), _sectionName(sectionName), _section(section),
         _contentData(contentData), _offset(offset) {
@@ -593,7 +593,7 @@ public:
 
   virtual bool isAlias() const { return false; }
 
-  virtual llvm::ArrayRef<uint8_t> rawContent() const { return _contentData; }
+  virtual ArrayRef<uint8_t> rawContent() const { return _contentData; }
 
   DefinedAtom::reference_iterator begin() const {
     uintptr_t index = 0;
@@ -617,7 +617,7 @@ private:
   StringRef _sectionName;
   const Elf_Shdr *_section;
   /// \brief Holds the bits that make up the atom.
-  llvm::ArrayRef<uint8_t> _contentData;
+  ArrayRef<uint8_t> _contentData;
   uint64_t _ordinal;
   uint64_t _offset;
 };

Modified: lld/trunk/lib/ReaderWriter/ELF/ELFLinkingContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/ELFLinkingContext.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/ELFLinkingContext.cpp (original)
+++ lld/trunk/lib/ReaderWriter/ELF/ELFLinkingContext.cpp Mon Nov  4 19:37:40 2013
@@ -134,7 +134,7 @@ ELFLinkingContext::create(llvm::Triple t
   }
 }
 
-llvm::ErrorOr<StringRef> ELFLinkingContext::searchLibrary(
+ErrorOr<StringRef> ELFLinkingContext::searchLibrary(
     StringRef libName, const std::vector<StringRef> &searchPath) const {
   bool foundFile = false;
   StringRef pathref;

Modified: lld/trunk/lib/ReaderWriter/ELF/File.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/File.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/File.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/File.h Mon Nov  4 19:37:40 2013
@@ -122,7 +122,7 @@ public:
       : File(name, kindObject), _elfLinkingContext(context) {}
 
   ELFFile(const ELFLinkingContext &context,
-          std::unique_ptr<llvm::MemoryBuffer> MB, llvm::error_code &EC)
+          std::unique_ptr<MemoryBuffer> MB, error_code &EC)
       : File(MB->getBufferIdentifier(), kindObject),
         _elfLinkingContext(context), _ordinal(0), _doStringsMerge(false) {
     _objFile.reset(new llvm::object::ELFFile<ELFT>(MB.release(), EC));

Modified: lld/trunk/lib/ReaderWriter/ELF/Reader.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/Reader.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/Reader.cpp (original)
+++ lld/trunk/lib/ReaderWriter/ELF/Reader.cpp Mon Nov  4 19:37:40 2013
@@ -90,7 +90,7 @@ public:
     std::size_t MaxAlignment =
         1ULL << llvm::countTrailingZeros(uintptr_t(mb->getBufferStart()));
 
-    llvm::error_code ec;
+    error_code ec;
     switch (FileType) {
     case llvm::sys::fs::file_magic::elf_relocatable: {
       std::unique_ptr<File> f(createELF<ELFFileCreateELFTraits>(

Modified: lld/trunk/lib/ReaderWriter/ELF/SectionChunks.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/SectionChunks.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/SectionChunks.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/SectionChunks.h Mon Nov  4 19:37:40 2013
@@ -378,7 +378,7 @@ void AtomSection<ELFT>::write(ELFWriter
     if (!definedAtom->occupiesDiskSpace())
       return;
     // Copy raw content of atom to file buffer.
-    llvm::ArrayRef<uint8_t> content = definedAtom->rawContent();
+    ArrayRef<uint8_t> content = definedAtom->rawContent();
     uint64_t contentSize = content.size();
     if (contentSize == 0)
       return;
@@ -817,9 +817,9 @@ void SymbolTable<ELFT>::addSymbol(const
   else if (const AbsoluteAtom *aa = dyn_cast<const AbsoluteAtom>(atom))
     addAbsoluteAtom(symbol, aa, addr);
   else if (isa<const SharedLibraryAtom>(atom))
-    addSharedLibAtom(symbol, llvm::dyn_cast<SharedLibraryAtom>(atom));
+    addSharedLibAtom(symbol, dyn_cast<SharedLibraryAtom>(atom));
   else
-    addUndefinedAtom(symbol, llvm::dyn_cast<UndefinedAtom>(atom));
+    addUndefinedAtom(symbol, dyn_cast<UndefinedAtom>(atom));
 
   _symbolTable.push_back(SymbolEntry(atom, symbol, atomLayout));
   this->_fsize += sizeof(Elf_Sym);

Modified: lld/trunk/lib/ReaderWriter/ELF/SegmentChunks.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ELF/SegmentChunks.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ELF/SegmentChunks.h (original)
+++ lld/trunk/lib/ReaderWriter/ELF/SegmentChunks.h Mon Nov  4 19:37:40 2013
@@ -548,7 +548,7 @@ template <class ELFT> void Segment<ELFT>
       // Check if the segment is of type TLS
       // The sections that belong to the TLS segment have their
       // virtual addresses that are relative To TP
-      Section<ELFT> *currentSection = llvm::dyn_cast<Section<ELFT> >(section);
+      Section<ELFT> *currentSection = dyn_cast<Section<ELFT> >(section);
       if (currentSection)
         isTLSSegment = (currentSection->getSegmentType() == llvm::ELF::PT_TLS);
 

Modified: lld/trunk/lib/ReaderWriter/LinkerScript.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/LinkerScript.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/LinkerScript.cpp (original)
+++ lld/trunk/lib/ReaderWriter/LinkerScript.cpp Mon Nov  4 19:37:40 2013
@@ -16,7 +16,7 @@
 
 namespace lld {
 namespace script {
-void Token::dump(llvm::raw_ostream &os) const {
+void Token::dump(raw_ostream &os) const {
   switch (_kind) {
 #define CASE(name)                              \
   case Token::name:                             \

Modified: lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFile.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFile.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFile.h (original)
+++ lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFile.h Mon Nov  4 19:37:40 2013
@@ -255,7 +255,7 @@ readYaml(std::unique_ptr<MemoryBuffer> &
 
 /// Writes a yaml encoded mach-o files given an in-memory normalized view.
 error_code 
-writeYaml(const NormalizedFile &file, llvm::raw_ostream &out);
+writeYaml(const NormalizedFile &file, raw_ostream &out);
 
 
 /// Takes in-memory normalized dylib or object and parses it into lld::File

Modified: lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp (original)
+++ lld/trunk/lib/ReaderWriter/MachO/MachONormalizedFileYAML.cpp Mon Nov  4 19:37:40 2013
@@ -416,7 +416,7 @@ struct MappingTraits<Symbol> {
 // Custom mapping for VMProtect (e.g. "r-x").
 template <>
 struct ScalarTraits<VMProtect> {
-  static void output(const VMProtect &value, void*, llvm::raw_ostream &out) {
+  static void output(const VMProtect &value, void*, raw_ostream &out) {
     out << ( (value & llvm::MachO::VM_PROT_READ)    ? 'r' : '-');
     out << ( (value & llvm::MachO::VM_PROT_WRITE)   ? 'w' : '-');
     out << ( (value & llvm::MachO::VM_PROT_EXECUTE) ? 'x' : '-');
@@ -641,7 +641,7 @@ readYaml(std::unique_ptr<MemoryBuffer> &
 
 /// Writes a yaml encoded mach-o files from an in-memory normalized view.
 error_code 
-writeYaml(const NormalizedFile &file, llvm::raw_ostream &out) {
+writeYaml(const NormalizedFile &file, raw_ostream &out) {
   // YAML I/O is not const aware, so need to cast away ;-(
   NormalizedFile *f = const_cast<NormalizedFile*>(&file);
 

Modified: lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp (original)
+++ lld/trunk/lib/ReaderWriter/Native/ReaderNative.cpp Mon Nov  4 19:37:40 2013
@@ -734,7 +734,7 @@ private:
   }
 
   // private constructor, only called by make()
-  File(const LinkingContext &context, std::unique_ptr<llvm::MemoryBuffer> mb,
+  File(const LinkingContext &context, std::unique_ptr<MemoryBuffer> mb,
        StringRef path)
       : lld::File(path, kindObject),
         _buffer(std::move(mb)), // Reader now takes ownership of buffer
@@ -787,7 +787,7 @@ private:
   };
 
 
-  std::unique_ptr<llvm::MemoryBuffer> _buffer;
+  std::unique_ptr<MemoryBuffer> _buffer;
   const NativeFileHeader*         _header;
   AtomArray<DefinedAtom>          _definedAtoms;
   AtomArray<UndefinedAtom>        _undefinedAtoms;

Modified: lld/trunk/lib/ReaderWriter/PECOFF/ReaderCOFF.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/PECOFF/ReaderCOFF.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/PECOFF/ReaderCOFF.cpp (original)
+++ lld/trunk/lib/ReaderWriter/PECOFF/ReaderCOFF.cpp Mon Nov  4 19:37:40 2013
@@ -140,14 +140,14 @@ private:
 
 public:
   FileCOFF(const LinkingContext &context,
-           std::unique_ptr<llvm::MemoryBuffer> mb, error_code &ec)
+           std::unique_ptr<MemoryBuffer> mb, error_code &ec)
       : File(mb->getBufferIdentifier(), kindObject), _context(context) {
-    llvm::OwningPtr<llvm::object::Binary> bin;
+    OwningPtr<llvm::object::Binary> bin;
     ec = llvm::object::createBinary(mb.release(), bin);
     if (ec)
       return;
 
-    _obj.reset(llvm::dyn_cast<const llvm::object::COFFObjectFile>(bin.get()));
+    _obj.reset(dyn_cast<const llvm::object::COFFObjectFile>(bin.get()));
     if (!_obj) {
       ec = make_error_code(llvm::object::object_error::invalid_file_type);
       return;
@@ -887,10 +887,10 @@ private:
     llvm::FileRemover coffFileRemover(*coffFilePath);
 
     // Read and parse the COFF
-    OwningPtr<llvm::MemoryBuffer> opmb;
-    if (error_code ec = llvm::MemoryBuffer::getFileOrSTDIN(*coffFilePath, opmb))
+    OwningPtr<MemoryBuffer> opmb;
+    if (error_code ec = MemoryBuffer::getFileOrSTDIN(*coffFilePath, opmb))
       return ec;
-    std::unique_ptr<llvm::MemoryBuffer> newmb(opmb.take());
+    std::unique_ptr<MemoryBuffer> newmb(opmb.take());
     return parseCOFFFile(newmb, result);
   }
 

Modified: lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.cpp (original)
+++ lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.cpp Mon Nov  4 19:37:40 2013
@@ -182,8 +182,8 @@ std::vector<uint8_t> FuncAtom::rawConten
 class FileImportLibrary : public File {
 public:
   FileImportLibrary(const LinkingContext &context,
-                    std::unique_ptr<llvm::MemoryBuffer> mb,
-                    llvm::error_code &ec)
+                    std::unique_ptr<MemoryBuffer> mb,
+                    error_code &ec)
       : File(mb->getBufferIdentifier(), kindSharedLibrary), _context(context) {
     const char *buf = mb->getBufferStart();
     const char *end = mb->getBufferEnd();

Modified: lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.h?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.h (original)
+++ lld/trunk/lib/ReaderWriter/PECOFF/ReaderImportHeader.h Mon Nov  4 19:37:40 2013
@@ -24,9 +24,9 @@ class File;
 
 namespace coff {
 
-llvm::error_code
+error_code
 parseCOFFImportLibrary(const LinkingContext &context,
-                       std::unique_ptr<llvm::MemoryBuffer> &mb,
+                       std::unique_ptr<MemoryBuffer> &mb,
                        std::vector<std::unique_ptr<File> > &result);
 }
 }

Modified: lld/trunk/lib/ReaderWriter/ReaderLinkerScript.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/ReaderLinkerScript.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/ReaderLinkerScript.cpp (original)
+++ lld/trunk/lib/ReaderWriter/ReaderLinkerScript.cpp Mon Nov  4 19:37:40 2013
@@ -21,7 +21,7 @@ class LinkerScriptFile : public File {
 public:
   static ErrorOr<std::unique_ptr<LinkerScriptFile> >
   create(const LinkingContext &context,
-         std::unique_ptr<llvm::MemoryBuffer> mb) {
+         std::unique_ptr<MemoryBuffer> mb) {
     std::unique_ptr<LinkerScriptFile> file(
         new LinkerScriptFile(context, std::move(mb)));
     file->_script = file->_parser.parse();
@@ -56,7 +56,7 @@ public:
 
 private:
   LinkerScriptFile(const LinkingContext &context,
-                   std::unique_ptr<llvm::MemoryBuffer> mb)
+                   std::unique_ptr<MemoryBuffer> mb)
       : File(mb->getBufferIdentifier(), kindLinkerScript), _context(context),
         _lexer(std::move(mb)), _parser(_lexer), _script(nullptr) {}
 
@@ -83,11 +83,11 @@ error_code ReaderLinkerScript::parseFile
   for (const auto &c : ls->_commands) {
     if (auto group = dyn_cast<lld::script::Group>(c))
       for (const auto &path : group->getPaths()) {
-        OwningPtr<llvm::MemoryBuffer> opmb;
+        OwningPtr<MemoryBuffer> opmb;
         if (error_code ec =
-                llvm::MemoryBuffer::getFileOrSTDIN(path._path, opmb))
+                MemoryBuffer::getFileOrSTDIN(path._path, opmb))
           return ec;
-        std::unique_ptr<llvm::MemoryBuffer> eachMB(opmb.take());
+        std::unique_ptr<MemoryBuffer> eachMB(opmb.take());
         if (error_code ec =
                 _context.getDefaultReader().parseFile(eachMB, result))
           return ec;

Modified: lld/trunk/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp?rev=194037&r1=194036&r2=194037&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp (original)
+++ lld/trunk/lib/ReaderWriter/YAML/ReaderWriterYAML.cpp Mon Nov  4 19:37:40 2013
@@ -90,7 +90,7 @@ public:
           std::string storage;
           llvm::raw_string_ostream buffer(storage);
           buffer << llvm::format("L%03d", _unnamedCounter++);
-          llvm::StringRef newName = copyString(buffer.str());
+          StringRef newName = copyString(buffer.str());
           _refNames[target] = newName;
           DEBUG_WITH_TYPE("WriterYAML",
                           llvm::dbgs() << "unnamed atom: creating ref-name: '"
@@ -119,7 +119,7 @@ public:
       std::string Storage;
       llvm::raw_string_ostream buffer(Storage);
       buffer << atom.name() << llvm::format(".%03d", ++_collisionCount);
-      llvm::StringRef newName = copyString(buffer.str());
+      StringRef newName = copyString(buffer.str());
       _refNames[&atom] = newName;
       DEBUG_WITH_TYPE("WriterYAML",
                       llvm::dbgs() << "name collsion: creating ref-name: '"
@@ -132,7 +132,7 @@ public:
         std::string Storage2;
         llvm::raw_string_ostream buffer2(Storage2);
         buffer2 << prevAtom->name() << llvm::format(".%03d", ++_collisionCount);
-        llvm::StringRef newName2 = copyString(buffer2.str());
+        StringRef newName2 = copyString(buffer2.str());
         _refNames[prevAtom] = newName2;
         DEBUG_WITH_TYPE("WriterYAML",
                         llvm::dbgs() << "name collsion: creating ref-name: '"
@@ -153,7 +153,7 @@ public:
 
   bool hasRefName(const lld::Atom *atom) { return _refNames.count(atom); }
 
-  llvm::StringRef refName(const lld::Atom *atom) {
+  StringRef refName(const lld::Atom *atom) {
     return _refNames.find(atom)->second;
   }
 
@@ -163,13 +163,13 @@ private:
 
   // Allocate a new copy of this string and keep track of allocations
   // in _stringCopies, so they can be freed when RefNameBuilder is destroyed.
-  llvm::StringRef copyString(llvm::StringRef str) {
+  StringRef copyString(StringRef str) {
     // We want _stringCopies to own the string memory so it is deallocated
     // when the File object is destroyed.  But we need a StringRef that
     // points into that memory.
     std::unique_ptr<char[]> s(new char[str.size()]);
     memcpy(s.get(), str.data(), str.size());
-    llvm::StringRef r = llvm::StringRef(s.get(), str.size());
+    StringRef r = StringRef(s.get(), str.size());
     _stringCopies.push_back(std::move(s));
     return r;
   }
@@ -187,12 +187,12 @@ class RefNameResolver {
 public:
   RefNameResolver(const lld::File *file, IO &io);
 
-  const lld::Atom *lookup(llvm::StringRef name) const {
+  const lld::Atom *lookup(StringRef name) const {
     NameToAtom::const_iterator pos = _nameMap.find(name);
     if (pos != _nameMap.end()) {
       return pos->second;
     } else {
-      _io.setError(llvm::Twine("no such atom name: ") + name);
+      _io.setError(Twine("no such atom name: ") + name);
       return nullptr;
     }
   }
@@ -200,9 +200,9 @@ public:
 private:
   typedef llvm::StringMap<const lld::Atom *> NameToAtom;
 
-  void add(llvm::StringRef name, const lld::Atom *atom) {
+  void add(StringRef name, const lld::Atom *atom) {
     if (_nameMap.count(name)) {
-      _io.setError(llvm::Twine("duplicate atom name: ") + name);
+      _io.setError(Twine("duplicate atom name: ") + name);
     } else {
       _nameMap[name] = atom;
     }
@@ -248,7 +248,7 @@ enum FileKinds {
 
 struct ArchMember {
   FileKinds _kind;
-  llvm::StringRef _name;
+  StringRef _name;
   const lld::File *_content;
 };
 
@@ -276,7 +276,7 @@ namespace yaml {
 
 // This is a custom formatter for RefKind
 template <> struct ScalarTraits<RefKind> {
-  static void output(const RefKind &value, void *ctxt, llvm::raw_ostream &out) {
+  static void output(const RefKind &value, void *ctxt, raw_ostream &out) {
     assert(ctxt != nullptr);
     ContextInfo *info = reinterpret_cast<ContextInfo *>(ctxt);
     switch (value) {
@@ -486,7 +486,7 @@ struct ScalarEnumerationTraits<lld::Shar
 ///     7 mod 2^4    # 16-byte aligned plus 7 bytes
 template <> struct ScalarTraits<lld::DefinedAtom::Alignment> {
   static void output(const lld::DefinedAtom::Alignment &value, void *ctxt,
-                     llvm::raw_ostream &out) {
+                     raw_ostream &out) {
     if (value.modulus == 0) {
       out << llvm::format("2^%d", value.powerOf2);
     } else {
@@ -555,12 +555,12 @@ template <typename T> struct SequenceTra
 // Used to allow DefinedAtom content bytes to be a flow sequence of
 // two-digit hex numbers without the leading 0x (e.g. FF, 04, 0A)
 template <> struct ScalarTraits<ImplicitHex8> {
-  static void output(const ImplicitHex8 &val, void *, llvm::raw_ostream &out) {
+  static void output(const ImplicitHex8 &val, void *, raw_ostream &out) {
     uint8_t num = val;
     out << llvm::format("%02X", num);
   }
 
-  static llvm::StringRef input(llvm::StringRef str, void *, ImplicitHex8 &val) {
+  static StringRef input(StringRef str, void *, ImplicitHex8 &val) {
     unsigned long long n;
     if (getAsUnsignedInteger(str, 16, n))
       return "invalid two-digit-hex number";
@@ -681,7 +681,7 @@ template <> struct MappingTraits<const l
       // points into that memory.
       std::unique_ptr<char[]> s(new char[str.size()]);
       memcpy(s.get(), str.data(), str.size());
-      llvm::StringRef r = llvm::StringRef(s.get(), str.size());
+      StringRef r = StringRef(s.get(), str.size());
       _stringCopies.push_back(std::move(s));
       return r;
     }
@@ -1211,11 +1211,11 @@ inline void MappingTraits<const lld::Ref
   _target = resolver.lookup(_targetName);
 }
 
-inline llvm::StringRef
+inline StringRef
 MappingTraits<const lld::Reference *>::NormalizedReference::targetName(
     IO &io, const lld::Reference *ref) {
   if (ref->target() == nullptr)
-    return llvm::StringRef();
+    return StringRef();
   ContextInfo *info = reinterpret_cast<ContextInfo *>(io.getContext());
   assert(info != nullptr);
   typedef MappingTraits<const lld::File *>::NormalizedFile NormalizedFile;





More information about the llvm-commits mailing list