Sequoia
Loading...
Searching...
No Matches
MonotonicSequenceDetails.hpp
Go to the documentation of this file.
1
2// Copyright Oliver J. Rosten 2019. //
3// Distributed under the GNU GENERAL PUBLIC LICENSE, Version 3.0. //
4// (See accompanying file LICENSE.md or copy at //
5// https://www.gnu.org/licenses/gpl-3.0.en.html) //
7
8#pragma once
9
15
16namespace sequoia::maths::impl
17{
18 template<class C> struct static_storage : std::false_type {};
19
20 template<class T, std::size_t N> struct static_storage<std::array<T, N>> : std::true_type
21 {
22 constexpr static std::size_t size() noexcept { return N; }
23 };
24
25 template<class C>
27 : std::bool_constant<
28 std::allocator_traits<typename C::allocator_type>::propagate_on_container_swap::value
29 || std::allocator_traits<typename C::allocator_type>::is_always_equal::value
30 >
31 {};
32
33 template<class C>
34 requires has_allocator_type_v<C>
35 struct noexcept_spec<C> : std::true_type
36 {};
37
38 template<class C>
39 inline constexpr bool noexcept_spec_v{noexcept_spec<C>::value};
40}
Concepts which are sufficiently general to appear in the sequoia namespace.
Definition: MonotonicSequenceDetails.hpp:31
Definition: MonotonicSequenceDetails.hpp:18