folly::Range::endsWith

endsWith overloads

Synopses

Declared in <folly/Range.h>

Does this Range end with another range?

bool
endsWith(const_range_type const& other) const;
» more...

Does this Range end with the given element?

bool
endsWith(value_type const& c) const;
» more...

Does this Range end with another range, using a custom comparator?

template<class Comp>
bool
endsWith(
    const_range_type const& other,
    Comp&& eq) 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.
eqThe equality comparison used to match elements.