view: use auto return type for indexing

This commit is contained in:
Danny Robson 2017-12-26 17:32:06 +11:00
parent 1123cfe409
commit 9704387fdc

View File

@ -210,7 +210,7 @@ namespace util {
///////////////////////////////////////////////////////////////////////
constexpr value_type&
constexpr auto&
operator[] (size_t idx)& noexcept
{
auto it = begin ();
@ -219,7 +219,7 @@ namespace util {
}
//---------------------------------------------------------------------
constexpr const value_type&
constexpr auto&
operator[] (size_t idx) const& noexcept
{
auto it = begin ();
@ -343,7 +343,6 @@ namespace util {
view<CharT*>
make_view (std::basic_string<CharT,TraitsT,AllocT>&&) = delete;
///////////////////////////////////////////////////////////////////////////
template <typename IteratorA, typename IteratorB>
constexpr bool