Returns the first of the non‐type template arguments V1, V2, Vs... whose type matches T

Synopsis

Declared in <mp‐units/ext/type_traits.h>

template<
    typename T,
    auto V1,
    auto V2,
    auto Vs...>
[[nodiscard]]
consteval
auto
get();

Return Value

The value of the first argument whose type matches T

Note

The return value should not be discarded.

Template Parameters

Name

Description

T

The type to look for among the types of V1, V2, Vs...

V1

The first non‐type template argument to check

V2

The second non‐type template argument to check

Vs

The remaining non‐type template arguments to check

Created with MrDocs