[lld] r331097 - Migrate from std::pointer_to_unary_function as it is removed in C++17
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 27 17:12:03 PDT 2018
Author: maskray
Date: Fri Apr 27 17:12:02 2018
New Revision: 331097
URL: http://llvm.org/viewvc/llvm-project?rev=331097&view=rev
Log:
Migrate from std::pointer_to_unary_function as it is removed in C++17
Modified:
lld/trunk/include/lld/Core/File.h
Modified: lld/trunk/include/lld/Core/File.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/include/lld/Core/File.h?rev=331097&r1=331096&r2=331097&view=diff
==============================================================================
--- lld/trunk/include/lld/Core/File.h (original)
+++ lld/trunk/include/lld/Core/File.h Fri Apr 27 17:12:02 2018
@@ -114,10 +114,8 @@ public:
AtomRange(AtomVector<T> &v) : _v(v) {}
AtomRange(const AtomVector<T> &v) : _v(const_cast<AtomVector<T> &>(v)) {}
- typedef std::pointer_to_unary_function<const OwningAtomPtr<T>&,
- const T*> ConstDerefFn;
-
- typedef std::pointer_to_unary_function<OwningAtomPtr<T>&, T*> DerefFn;
+ using ConstDerefFn = const T* (*)(const OwningAtomPtr<T>&);
+ using DerefFn = T* (*)(OwningAtomPtr<T>&);
typedef llvm::mapped_iterator<typename AtomVector<T>::const_iterator,
ConstDerefFn> ConstItTy;
More information about the llvm-commits
mailing list