tetl
0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
at.hpp
Go to the documentation of this file.
1
// SPDX-License-Identifier: BSL-1.0
2
3
#ifndef TETL_META_AT_HPP
4
#define TETL_META_AT_HPP
5
6
#include <
etl/_cstddef/size_t.hpp
>
7
#include <
etl/_meta/list.hpp
>
8
9
namespace
etl::meta
{
10
11
template
<etl::
size_t
I,
typename
List>
12
struct
at
;
13
14
template
<
typename
Head,
typename
... Tail>
15
struct
at
<0,
list
<Head, Tail...>> {
16
using
type
= Head;
17
};
18
19
template
<
etl::size_t
I,
typename
Head,
typename
... Tail>
20
struct
at
<I,
list
<Head, Tail...>> {
21
using
type
=
typename
at
<I - 1,
list
<Tail...>>
::type
;
22
};
23
24
template
<etl::
size_t
I,
typename
List>
25
using
at_t
=
typename
at<I, List>::type
;
26
27
}
// namespace etl::meta
28
29
#endif
// TETL_META_AT_HPP
list.hpp
etl::meta
Definition
at.hpp:9
etl::meta::at_t
typename at< I, List >::type at_t
Definition
at.hpp:25
etl::size_t
TETL_BUILTIN_SIZET size_t
etl::size_t is the unsigned integer type of the result of the sizeof operator.
Definition
size_t.hpp:14
size_t.hpp
etl::meta::at< 0, list< Head, Tail... > >::type
Head type
Definition
at.hpp:16
etl::meta::at< I, list< Head, Tail... > >::type
typename at< I - 1, list< Tail... > >::type type
Definition
at.hpp:21
etl::meta::at
Definition
at.hpp:12
etl::meta::list
Definition
list.hpp:10
include
etl
_meta
at.hpp
Generated on Sat Mar 8 2025 16:19:59 for tetl by
1.14.0