std::mdspan<T,Extents,LayoutPolicy,AccessorPolicy>::operator[]

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

# Return value

A reference to the element.

# Example

This section is incompleteReason: no example

# Defect reports

DRApplied toBehavior as publishedCorrect behavior
LWG 3974C++23overloads (2,3) did not apply extents_type::index-castapplies