[llvm] r208219 - llvm-cov: Explicitly namespace llvm::make_unique to keep MSVC happy

Justin Bogner mail at justinbogner.com
Wed May 7 09:01:27 PDT 2014


Author: bogner
Date: Wed May  7 11:01:27 2014
New Revision: 208219

URL: http://llvm.org/viewvc/llvm-project?rev=208219&view=rev
Log:
llvm-cov: Explicitly namespace llvm::make_unique to keep MSVC happy

This is a followup to r208171, where a call to make_unique was
disambiguated for MSVC. Disambiguate two more calls, and remove the
comment about it since this is what we do everywhere.

Modified:
    llvm/trunk/lib/IR/GCOV.cpp

Modified: llvm/trunk/lib/IR/GCOV.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/GCOV.cpp?rev=208219&r1=208218&r2=208219&view=diff
==============================================================================
--- llvm/trunk/lib/IR/GCOV.cpp (original)
+++ llvm/trunk/lib/IR/GCOV.cpp Wed May  7 11:01:27 2014
@@ -511,16 +511,14 @@ std::string FileInfo::getCoveragePath(St
 std::unique_ptr<raw_ostream>
 FileInfo::openCoveragePath(StringRef CoveragePath) {
   if (Options.NoOutput)
-    return make_unique<raw_null_ostream>();
+    return llvm::make_unique<raw_null_ostream>();
 
   std::string ErrorInfo;
-  // FIXME: When using MSVS, we end up having both std::make_unique and
-  // llvm::make_unique which conflict.  Explicitly use the llvm:: version.
   auto OS = llvm::make_unique<raw_fd_ostream>(CoveragePath.str().c_str(),
                                               ErrorInfo, sys::fs::F_Text);
   if (!ErrorInfo.empty()) {
     errs() << ErrorInfo << "\n";
-    return make_unique<raw_null_ostream>();
+    return llvm::make_unique<raw_null_ostream>();
   }
   return std::move(OS);
 }





More information about the llvm-commits mailing list