@@ -1974,6 +1974,7 @@ struct const_subarray : array_types<T, D, ElementPtr, Layout> {
19741974 }
19751975 }
19761976
1977+ // / Returns a const-element view of the array, preventing modification of elements.
19771978 constexpr auto as_const () const {
19781979 return rebind<element, element_const_ptr>{this ->layout (), this ->base ()};
19791980 }
@@ -2770,6 +2771,7 @@ struct array_iterator<Element, 1, Ptr, IsConst, IsMove, Stride> // NOLINT(fuchs
27702771// template<class Element, dimensionality_type D, typename... Ts>
27712772// using iterator = array_iterator<Element, D, Ts...>;
27722773
2774+ // / ... a specialization for zero dimensions
27732775template <typename T, typename ElementPtr, class Layout >
27742776class const_subarray <T, 0 , ElementPtr, Layout>
27752777: public array_types<T, 0 , ElementPtr, Layout> {
@@ -2919,6 +2921,7 @@ class const_subarray<T, 0, ElementPtr, Layout>
29192921#pragma clang diagnostic ignored "-Wpadded"
29202922#endif
29212923
2924+ // / ... a specialization for one dimension
29222925template <typename T, typename ElementPtr, class Layout >
29232926struct const_subarray <T, 1 , ElementPtr, Layout> // NOLINT(fuchsia-multiple-inheritance,misc-multiple-inheritance) to define operators via CRTP
29242927: multi::random_iterable<const_subarray<T, 1 , ElementPtr, Layout>>
0 commit comments