4#ifndef TETL_TYPE_TRAITS_IS_NOTHROW_CONSTRUCTIBLE_HPP
5#define TETL_TYPE_TRAITS_IS_NOTHROW_CONSTRUCTIBLE_HPP
7#include <etl/_config/all.hpp>
9#include <etl/_type_traits/bool_constant.hpp>
10#include <etl/_type_traits/declval.hpp>
11#include <etl/_type_traits/remove_all_extents.hpp>
16template <
bool,
typename T,
typename... Args>
17struct nothrow_constructible_impl : false_type { };
19template <
typename T,
typename... Args>
20struct nothrow_constructible_impl<
true, T, Args...> : bool_constant<
noexcept(T(declval<Args>()...))> { };
22template <
typename T,
typename Arg>
23struct nothrow_constructible_impl<
true, T, Arg> : bool_constant<
noexcept(
static_cast<T>(declval<Arg>()))> { };
26struct nothrow_constructible_impl<
true, T> : bool_constant<
noexcept(T())> { };
28template <
typename T, size_t Size>
29struct nothrow_constructible_impl<
true, T[Size]> : bool_constant<
noexcept(remove_all_extents_t<T>())> { };
31#if defined(__cpp_aggregate_paren_init)
32template <
typename T, size_t Size,
typename Arg>
33struct nothrow_constructible_impl<
true, T[Size], Arg> : nothrow_constructible_impl<
true, T, Arg> { };
35template <
typename T, size_t Size,
typename... Args>
36struct nothrow_constructible_impl<
true, T[Size], Args...>
37 : bool_constant<(nothrow_constructible_impl<
true, T, Args>::value && ...)> { };
40template <
typename T,
typename... Args>
41using is_nothrow_constructible_helper = nothrow_constructible_impl<
__is_constructible(T, Args...), T, Args...>;
47template <
typename T,
typename... Args>
50template <
typename T,
typename...
Args>
Definition adjacent_find.hpp:9
constexpr bool is_nothrow_constructible_v
Definition is_nothrow_constructible.hpp:51
The variable definition does not call any operation that is not trivial. For the purposes of this che...
Definition is_nothrow_constructible.hpp:48