tetl
0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
coroutine_traits.hpp
Go to the documentation of this file.
1
// SPDX-License-Identifier: BSL-1.0
2
// SPDX-FileCopyrightText: Copyright (C) 2021 Tobias Hienzsch
3
4
#
ifndef
TETL_COROUTINE_COROUTINE_TRAITS_HPP
5
#
define
TETL_COROUTINE_COROUTINE_TRAITS_HPP
6
7
#
include
<
etl
/
_type_traits
/
void_t
.
hpp
>
8
9
#
if
defined
(
__cpp_coroutines
)
10
11
namespace
etl {
12
13
namespace
detail {
14
template
<
typename
R,
typename
=
void
>
15
struct
coro_traits { };
16
17
template
<
typename
R>
18
struct
coro_traits<R, void_t<
typename
R::promise_type>> {
19
using
promise_type =
typename
R::promise_type;
20
};
21
}
// namespace detail
22
23
/// \ingroup coroutine
24
template
<
typename
R,
typename
... Args>
25
struct
coroutine_traits : detail::coro_traits<R> { };
26
27
}
// namespace etl
28
29
#
endif
// defined(__cpp_coroutines)
30
31
#
endif
// TETL_COROUTINE_COROUTINE_TRAITS_HPP
include
etl
_coroutine
coroutine_traits.hpp
Generated on Sun Sep 7 2025 19:14:53 for tetl by
1.9.8