Constructs a span wrapping an initializer list, applying a transform.
Declared in <absl/types/any_span.h>
template<
typename Element,
typename Transform,
typename = EnableIfTransformIsValid<Transform, Element const&>,
EnableIfTransformIsByCopy<Transform> = true>
constexpr
AnySpan(
std::initializer_list<Element> l,
Transform const& transform);
Useful for a list of a type other than value_type. The transform is taken by copy. The initializer list must outlive this span.
| Name | Description |
|---|---|
| l | The initializer list whose elements the span refers to. |
| transform | Functor applied to each element on access. |