17 lines
268 B
C++
17 lines
268 B
C++
|
#pragma once
|
||
|
|
||
|
template <class Derived>
|
||
|
struct TotalOrdering
|
||
|
{
|
||
|
friend bool operator!=(const Derived& a, const Derived& b)
|
||
|
{
|
||
|
return !(a == b);
|
||
|
}
|
||
|
|
||
|
friend bool operator>(const Derived& a, const Derived& b)
|
||
|
{
|
||
|
return !(a == b);
|
||
|
}
|
||
|
|
||
|
};
|