diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-02-07 12:04:33 +0000 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2021-02-07 12:04:33 +0000 |
commit | 68832526efafb4db60e5627eba6a9051585a4eb9 (patch) | |
tree | cb6059828786a60fa10c2017f43b7baf98ca86cc /utility/sorting.hpp | |
parent | Links have length, ends have entry direction (diff) | |
download | ilt-68832526efafb4db60e5627eba6a9051585a4eb9.tar.bz2 ilt-68832526efafb4db60e5627eba6a9051585a4eb9.tar.xz ilt-68832526efafb4db60e5627eba6a9051585a4eb9.zip |
Factor a lot of maths and stuff into utility
Diffstat (limited to 'utility/sorting.hpp')
-rw-r--r-- | utility/sorting.hpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/utility/sorting.hpp b/utility/sorting.hpp new file mode 100644 index 0000000..0cb0eaf --- /dev/null +++ b/utility/sorting.hpp @@ -0,0 +1,12 @@ +#ifndef SORTING_H +#define SORTING_H + +template<typename T> struct PtrSorter { + bool + operator()(const T & a, const T & b) const + { + return *a < *b; + } +}; + +#endif |