This revision was automatically updated to reflect the committed changes.
Closed by commit rL372201: [Support] Replace function with function_ref in 
writeFileAtomically. NFC (authored by ibiryukov, committed by ).
Herald added a subscriber: kristina.

Changed prior to commit:
  https://reviews.llvm.org/D67584?vs=220209&id=220620#toc

Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67584/new/

https://reviews.llvm.org/D67584

Files:
  llvm/trunk/include/llvm/Support/FileUtilities.h
  llvm/trunk/lib/Support/FileUtilities.cpp


Index: llvm/trunk/lib/Support/FileUtilities.cpp
===================================================================
--- llvm/trunk/lib/Support/FileUtilities.cpp
+++ llvm/trunk/lib/Support/FileUtilities.cpp
@@ -296,7 +296,7 @@
 
 llvm::Error llvm::writeFileAtomically(
     StringRef TempPathModel, StringRef FinalPath,
-    std::function<llvm::Error(llvm::raw_ostream &)> Writer) {
+    llvm::function_ref<llvm::Error(llvm::raw_ostream &)> Writer) {
   SmallString<128> GeneratedUniqPath;
   int TempFD;
   if (sys::fs::createUniqueFile(TempPathModel.str(), TempFD,
Index: llvm/trunk/include/llvm/Support/FileUtilities.h
===================================================================
--- llvm/trunk/include/llvm/Support/FileUtilities.h
+++ llvm/trunk/include/llvm/Support/FileUtilities.h
@@ -14,6 +14,7 @@
 #ifndef LLVM_SUPPORT_FILEUTILITIES_H
 #define LLVM_SUPPORT_FILEUTILITIES_H
 
+#include "llvm/ADT/STLExtras.h"
 #include "llvm/ADT/StringRef.h"
 #include "llvm/Support/Errc.h"
 #include "llvm/Support/ErrorHandling.h"
@@ -107,9 +108,9 @@
   llvm::Error writeFileAtomically(StringRef TempPathModel, StringRef FinalPath,
                                   StringRef Buffer);
 
-  llvm::Error
-  writeFileAtomically(StringRef TempPathModel, StringRef FinalPath,
-                      std::function<llvm::Error(llvm::raw_ostream &)> Writer);
+  llvm::Error writeFileAtomically(
+      StringRef TempPathModel, StringRef FinalPath,
+      llvm::function_ref<llvm::Error(llvm::raw_ostream &)> Writer);
 } // End llvm namespace
 
 #endif


Index: llvm/trunk/lib/Support/FileUtilities.cpp
===================================================================
--- llvm/trunk/lib/Support/FileUtilities.cpp
+++ llvm/trunk/lib/Support/FileUtilities.cpp
@@ -296,7 +296,7 @@
 
 llvm::Error llvm::writeFileAtomically(
     StringRef TempPathModel, StringRef FinalPath,
-    std::function<llvm::Error(llvm::raw_ostream &)> Writer) {
+    llvm::function_ref<llvm::Error(llvm::raw_ostream &)> Writer) {
   SmallString<128> GeneratedUniqPath;
   int TempFD;
   if (sys::fs::createUniqueFile(TempPathModel.str(), TempFD,
Index: llvm/trunk/include/llvm/Support/FileUtilities.h
===================================================================
--- llvm/trunk/include/llvm/Support/FileUtilities.h
+++ llvm/trunk/include/llvm/Support/FileUtilities.h
@@ -14,6 +14,7 @@
 #ifndef LLVM_SUPPORT_FILEUTILITIES_H
 #define LLVM_SUPPORT_FILEUTILITIES_H
 
+#include "llvm/ADT/STLExtras.h"
 #include "llvm/ADT/StringRef.h"
 #include "llvm/Support/Errc.h"
 #include "llvm/Support/ErrorHandling.h"
@@ -107,9 +108,9 @@
   llvm::Error writeFileAtomically(StringRef TempPathModel, StringRef FinalPath,
                                   StringRef Buffer);
 
-  llvm::Error
-  writeFileAtomically(StringRef TempPathModel, StringRef FinalPath,
-                      std::function<llvm::Error(llvm::raw_ostream &)> Writer);
+  llvm::Error writeFileAtomically(
+      StringRef TempPathModel, StringRef FinalPath,
+      llvm::function_ref<llvm::Error(llvm::raw_ostream &)> Writer);
 } // End llvm namespace
 
 #endif
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to