llvm::is_sorted_constexpr

is_sorted_constexpr overloads

Synopses

Declared in <llvm/ADT/STLExtras.h>

Return true if Range is sorted under comparator C.

template<
    typename R,
    typename Cmp = std::less<>>
constexpr
bool
is_sorted_constexpr(
    R&& Range,
    Cmp C = Cmp{});
» more...

Check whether []First, Last) is sorted under comparator C.

template<
    typename ForwardIterator,
    typename Cmp = std::less<>>
constexpr
bool
is_sorted_constexpr(
    ForwardIterator First,
    ForwardIterator Last,
    Cmp C = Cmp{});
» more...

Return Value

  • True if Range is sorted under comparator C.
  • True if []First, Last) is sorted under C.

Parameters

NameDescription
RangeRange to test.
CComparison function object.
FirstBeginning of the range.
LastEnd of the range.