...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
boost::stl_interfaces::view_interface
// In header: <boost/stl_interfaces/view_interface.hpp> template<typename Derived, element_layout Contiguity> struct view_interface { // public member functions template<typename D = Derived> constexpr auto empty() noexcept(noexcept(std::declval< D & >().begin()==std::declval< D & >().end())); template<typename D = Derived> constexpr auto empty() const noexcept(noexcept(std::declval< D const & >().begin()==std::declval< D const & >().end())); template<typename D = Derived, typename R = decltype(std::declval<D &>().empty())> explicit constexpr operator bool() noexcept(noexcept(std::declval< D & >().empty())); template<typename D = Derived, typename R = decltype(std::declval<D const &>().empty())> explicit constexpr operator bool() const noexcept(noexcept(std::declval< D const & >().empty())); template<typename D = Derived, element_layout C = Contiguity, typename Enable = std::enable_if_t<C == element_layout::contiguous> > constexpr auto data() noexcept(noexcept(std::declval< D & >().begin())); template<typename D = Derived, element_layout C = Contiguity, typename Enable = std::enable_if_t<C == element_layout::contiguous> > constexpr auto data() const noexcept(noexcept(std::declval< D const & >().begin())); template<typename D = Derived> constexpr auto size() noexcept(noexcept(std::declval< D & >().end() - std::declval< D & >().begin())); template<typename D = Derived> constexpr auto size() const noexcept(noexcept(std::declval< D const & >().end() - std::declval< D const & >().begin())); template<typename D = Derived> constexpr auto front() noexcept(noexcept(*std::declval< D & >().begin())); template<typename D = Derived> constexpr auto front() const noexcept(noexcept(*std::declval< D const & >().begin())); template<typename D = Derived, typename Enable = std::enable_if_t< v1_dtl::decrementable_sentinel<D>::value && v1_dtl::common_range<D>::value> > constexpr auto back() noexcept(noexcept(*std::prev(std::declval< D & >().end()))); template<typename D = Derived, typename Enable = std::enable_if_t< v1_dtl::decrementable_sentinel<D>::value && v1_dtl::common_range<D>::value> > constexpr auto back() const noexcept(noexcept(*std::prev(std::declval< D const & >().end()))); template<typename D = Derived> constexpr auto operator[](v1_dtl::range_difference_t< D >) noexcept(noexcept(std::declval< D & >().begin()[n])); template<typename D = Derived> constexpr auto operator[](v1_dtl::range_difference_t< D >) const noexcept(noexcept(std::declval< D const & >().begin()[n])); };
view_interface
public member functionstemplate<typename D = Derived> constexpr auto empty() noexcept(noexcept(std::declval< D & >().begin()==std::declval< D & >().end()));
template<typename D = Derived> constexpr auto empty() const noexcept(noexcept(std::declval< D const & >().begin()==std::declval< D const & >().end()));
template<typename D = Derived, typename R = decltype(std::declval<D &>().empty())> explicit constexpr operator bool() noexcept(noexcept(std::declval< D & >().empty()));
template<typename D = Derived, typename R = decltype(std::declval<D const &>().empty())> explicit constexpr operator bool() const noexcept(noexcept(std::declval< D const & >().empty()));
template<typename D = Derived, element_layout C = Contiguity, typename Enable = std::enable_if_t<C == element_layout::contiguous> > constexpr auto data() noexcept(noexcept(std::declval< D & >().begin()));
template<typename D = Derived, element_layout C = Contiguity, typename Enable = std::enable_if_t<C == element_layout::contiguous> > constexpr auto data() const noexcept(noexcept(std::declval< D const & >().begin()));
template<typename D = Derived> constexpr auto size() noexcept(noexcept(std::declval< D & >().end() - std::declval< D & >().begin()));
template<typename D = Derived> constexpr auto size() const noexcept(noexcept(std::declval< D const & >().end() - std::declval< D const & >().begin()));
template<typename D = Derived> constexpr auto front() noexcept(noexcept(*std::declval< D & >().begin()));
template<typename D = Derived> constexpr auto front() const noexcept(noexcept(*std::declval< D const & >().begin()));
template<typename D = Derived, typename Enable = std::enable_if_t< v1_dtl::decrementable_sentinel<D>::value && v1_dtl::common_range<D>::value> > constexpr auto back() noexcept(noexcept(*std::prev(std::declval< D & >().end())));
template<typename D = Derived, typename Enable = std::enable_if_t< v1_dtl::decrementable_sentinel<D>::value && v1_dtl::common_range<D>::value> > constexpr auto back() const noexcept(noexcept(*std::prev(std::declval< D const & >().end())));
template<typename D = Derived> constexpr auto operator[](v1_dtl::range_difference_t< D > n) noexcept(noexcept(std::declval< D & >().begin()[n]));
template<typename D = Derived> constexpr auto operator[](v1_dtl::range_difference_t< D > n) const noexcept(noexcept(std::declval< D const & >().begin()[n]));