folly::Range::ends_with

ends_with overloads

Synopses

Declared in <folly/Range.h>

Does this Range end with another range?

bool
ends_with(const_range_type other) const noexcept;
» more...

Does this Range end with the given element?

bool
ends_with(value_type const& c) const noexcept;
» more...

Does this Range end with the given null-terminated string?

template<
    typename...,
    typename T = Iter,
    int = 0>
requires detail::range_is_char_type_v_<T>
bool
ends_with(value_type const* other) const;
» more...

Return Value

  • True if this range ends with other.
  • True if the last element equals c.

Parameters

NameDescription
otherThe suffix range to test for.
cThe element to test for.