3 #include <boost/range/algorithm/lexicographical_compare.hpp> 26 template <Automaton Lhs, Automaton Rhs>
31 (lhs->all_transitions(),
32 rhs->all_transitions(),
36 if (
auto res =
int(lhs->src_of(t1)) -
int(rhs->src_of(t2)))
39 else if (
auto res = lhs->labelset()->compare(lhs->label_of(t1),
43 else if (
auto res = lhs->weightset()->compare(lhs->weight_of(t1),
48 return int(lhs->dst_of(t1)) -
int(rhs->dst_of(t2));
57 template <Automaton Lhs, Automaton Rhs>
61 const auto& l = lhs->
as<Lhs>();
62 const auto&
r = rhs->
as<Rhs>();
69 template <Automaton Lhs, Automaton Rhs>
77 template <Automaton Lhs, Automaton Rhs>
int lexicographical_cmp(InputIt1 first1, InputIt1 last1, InputIt2 first2, InputIt2 last2, Compare comp)
Lexicographical three-way comparison between two ranges.
int compare(const automaton &lhs, const automaton &rhs)
Bridge (compare).
Provide a variadic mul on top of a binary mul(), and one().
auto & as()
Extract wrapped typed automaton.
bool less_than(const automaton &lhs, const automaton &rhs)
Ordering between automata.
typename detail::transition_t_of_impl< base_t< ValueSet > >::type transition_t_of
int compare(const Lhs &lhs, const Rhs &rhs)
Comparison between lhs and rhs.
bool are_equal(const automaton &lhs, const automaton &rhs)
Whether are the same automaton.