view: we really don't need a dedicated find function

This commit is contained in:
Danny Robson 2017-08-30 15:13:24 +10:00
parent 9da28a64c9
commit 4a92981379

View File

@ -63,15 +63,6 @@ namespace util {
auto data (void) { return begin (); }
auto data (void) const { return begin (); }
constexpr T
find (const value_type &v) const noexcept
{
for (T i = cbegin (); i != cend (); ++i)
if (*i == v)
return i;
return cend ();
}
constexpr bool
empty (void) const noexcept
{
@ -112,6 +103,7 @@ namespace util {
T m_end;
};
template <typename T, size_t N>
auto
make_view (const T (&arr)[N])