r298663 - Remove uses of std::binary_function, removed in C++17.

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 23 16:32:03 PDT 2017


Author: rsmith
Date: Thu Mar 23 18:32:03 2017
New Revision: 298663

URL: http://llvm.org/viewvc/llvm-project?rev=298663&view=rev
Log:
Remove uses of std::binary_function, removed in C++17.

Modified:
    cfe/trunk/include/clang/AST/TypeOrdering.h
    cfe/trunk/include/clang/Basic/SourceLocation.h

Modified: cfe/trunk/include/clang/AST/TypeOrdering.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/TypeOrdering.h?rev=298663&r1=298662&r2=298663&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/TypeOrdering.h (original)
+++ cfe/trunk/include/clang/AST/TypeOrdering.h Thu Mar 23 18:32:03 2017
@@ -26,7 +26,7 @@
 namespace clang {
 
 /// \brief Function object that provides a total ordering on QualType values.
-struct QualTypeOrdering : std::binary_function<QualType, QualType, bool> {
+struct QualTypeOrdering {
   bool operator()(QualType T1, QualType T2) const {
     return std::less<void*>()(T1.getAsOpaquePtr(), T2.getAsOpaquePtr());
   }

Modified: cfe/trunk/include/clang/Basic/SourceLocation.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/SourceLocation.h?rev=298663&r1=298662&r2=298663&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/SourceLocation.h (original)
+++ cfe/trunk/include/clang/Basic/SourceLocation.h Thu Mar 23 18:32:03 2017
@@ -321,8 +321,7 @@ public:
   }
 
   /// \brief Comparison function class, useful for sorting FullSourceLocs.
-  struct BeforeThanCompare : public std::binary_function<FullSourceLoc,
-                                                         FullSourceLoc, bool> {
+  struct BeforeThanCompare {
     bool operator()(const FullSourceLoc& lhs, const FullSourceLoc& rhs) const {
       return lhs.isBeforeInTranslationUnitThan(rhs);
     }




More information about the cfe-commits mailing list