4 /// handy notations for a signed comparison
5 #define instantiate_compare(type, function) \
6 inline bool operator>(type t1, type t2) { return function(t1, t2) > 0; } \
7 inline bool operator>=(type t1, type t2) { return function(t1, t2) >= 0; } \
8 inline bool operator==(type t1, type t2) { return function(t1, t2) == 0; } \
9 inline bool operator<=(type t1, type t2) { return function(t1, t2) <= 0; } \
10 inline bool operator<(type t1, type t2) { return function(t1, t2) < 0; } \
11 inline type MAX(type t1, type t2) { return (t1 > t2 )? t1 : t2; }\
12 inline type MIN(type t1, type t2) { return (t1 < t2 )? t1 : t2; }\
14 bool operator<(type t1, type t2) /* stupid fix to allow ; */
16 make the operators{<,<=,==,>=,>} and the MAX and MIN of two.
17 Please fill a & in the type argument if necessary.