std::mdspan<T,Extents,LayoutPolicy,AccessorPolicy>::operator[]
Min standard notice:
Returns a reference to the indicesth element of the mdspan.
# Declarations
template< class... OtherIndexTypes >
constexpr reference operator[]( OtherIndexTypes... indices ) const;
(since C++23)
template< class OtherIndexType >
constexpr reference operator[]
( std::span<OtherIndexType, rank()> indices ) const;
(since C++23)
template< class OtherIndexType >
constexpr reference operator[]
( const std::array<OtherIndexType, rank()>& indices ) const;
(since C++23)
# Parameters
indices: the indices of the element to access
# Return value
A reference to the element.
# Example
This section is incompleteReason: no example
# Defect reports
| DR | Applied to | Behavior as published | Correct behavior |
|---|---|---|---|
| LWG 3974 | C++23 | overloads (2,3) did not apply extents_type::index-cast | applies |