[llvm-commits] CVS: llvm/include/Support/STLExtras.h
Alkis Evlogimenos
alkis at cs.uiuc.edu
Wed Jul 21 01:38:16 PDT 2004
Changes in directory llvm/include/Support:
STLExtras.h updated: 1.16 -> 1.17
---
Log message:
Add greater_ptr functor.
---
Diffs of the changes: (+7 -0)
Index: llvm/include/Support/STLExtras.h
diff -u llvm/include/Support/STLExtras.h:1.16 llvm/include/Support/STLExtras.h:1.17
--- llvm/include/Support/STLExtras.h:1.16 Sun May 30 02:45:09 2004
+++ llvm/include/Support/STLExtras.h Wed Jul 21 03:38:06 2004
@@ -60,6 +60,13 @@
}
};
+template<class Ty>
+struct greater_ptr : public std::binary_function<Ty, Ty, bool> {
+ bool operator()(const Ty* left, const Ty* right) const {
+ return *right < *left;
+ }
+};
+
// deleter - Very very very simple method that is used to invoke operator
// delete on something. It is used like this:
//
More information about the llvm-commits
mailing list