ShortLexCompare

template<typename T>
struct libsemigroups::ShortLexCompare

Defined in order.hpp.

A stateless struct with binary call operator using shortlex_compare.

This only exists to be used as a template parameter, and has no advantages over using shortlex_compare otherwise.

See also

shortlex_compare(T const, T const, S const, S const)

Template Parameters

T – the type of the objects to be compared.

Public Functions

inline bool operator()(T const &x, T const &y)

Call operator that compares x and y using shortlex_compare.

Complexity

See shortlex_compare(T const, T const, S const, S const).

Parameters
  • x – const reference to the first object for comparison

  • y – const reference to the second object for comparison

Throws

(None) – See shortlex_compare(T const, T const, S const, S const).

Returns

A bool.