feat(library/expr_lt): add expr_quick_cmp functional object

Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
Leonardo de Moura 2014-05-29 13:34:16 -07:00
parent 88440cbb3e
commit f8e71f711f

View file

@ -19,4 +19,5 @@ inline bool operator<(expr const & a, expr const & b) { return is_lt(a, b, true
inline bool operator>(expr const & a, expr const & b) { return is_lt(b, a, true); }
inline bool operator<=(expr const & a, expr const & b) { return !is_lt(b, a, true); }
inline bool operator>=(expr const & a, expr const & b) { return !is_lt(a, b, true); }
struct expr_quick_cmp { int operator()(expr const & e1, expr const & e2) const { return is_lt(e1, e2, true) ? -1 : (e1 == e2 ? 0 : 1); } };
}