Range-v3 Range algorithms, views, and actions for the Standard Library |

Public Member Functions | List of all members
ranges::index_fn Struct Reference
Range

## Description

Unchecked indexed range access.

## Public Member Functions
template<typename Rng , typename Int >
constexpr range_reference_t< Rng > | operator() (Rng &&rng, Int n) const

## Member Function Documentation

## ◆ operator()()

template<typename Rng , typename Int >

constexpr range_reference_t<Rng> ranges::index_fn::operator() | ( | Rng && | rng,
|  | Int | n
| ) |  | const
| constexpr

Returns
  `begin(rng)[n]`

Precondition
  requires `random_access_range<Rng> && integral<Int> && borrowed_range<Rng>`