Skip to content

Commit e0b716e

Browse files
committed
f
1 parent b3fe830 commit e0b716e

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

include/fast_io_core_impl/allocation/adapters.h

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1754,9 +1754,10 @@ namespace details
17541754
{
17551755

17561756
template <typename alloc, bool zero>
1757-
requires(::fast_io::generic_allocator_adapter<alloc>::has_native_allocate)
17581757
inline constexpr void *allocator_pointer_aligned_impl(::std::size_t alignment, ::std::size_t n) noexcept
1759-
{
1758+
{
1759+
static_assert(::fast_io::generic_allocator_adapter<alloc>::has_native_allocate);
1760+
17601761
constexpr ::std::size_t defaultalignment{::fast_io::details::calculate_default_alignment<alloc>()};
17611762
bool const alignedadjustment{defaultalignment < alignment};
17621763
if (alignedadjustment)
@@ -1780,9 +1781,10 @@ inline constexpr void *allocator_pointer_aligned_impl(::std::size_t alignment, :
17801781
}
17811782

17821783
template <typename alloc, bool zero>
1783-
requires(::fast_io::generic_allocator_adapter<alloc>::has_native_allocate)
17841784
inline constexpr ::fast_io::allocation_least_result allocator_pointer_aligned_at_least_impl(::std::size_t alignment, ::std::size_t n) noexcept
1785-
{
1785+
{
1786+
static_assert(::fast_io::generic_allocator_adapter<alloc>::has_native_allocate);
1787+
17861788
constexpr ::std::size_t defaultalignment{::fast_io::details::calculate_default_alignment<alloc>()};
17871789
bool const alignedadjustment{defaultalignment < alignment};
17881790
if (alignedadjustment)
@@ -1809,9 +1811,10 @@ inline constexpr ::fast_io::allocation_least_result allocator_pointer_aligned_at
18091811

18101812
#if 0
18111813
template <typename alloc, bool zero>
1812-
requires(::fast_io::generic_allocator_adapter<alloc>::has_native_handle_allocate)
18131814
inline constexpr void *status_allocator_pointer_aligned_impl(typename alloc::handle_type handle, ::std::size_t alignment, ::std::size_t n) noexcept
18141815
{
1816+
static_assert(::fast_io::generic_allocator_adapter<alloc>::has_native_handle_allocate);
1817+
18151818
constexpr ::std::size_t defaultalignment{::fast_io::details::calculate_default_alignment<alloc>()};
18161819
bool const alignedadjustment{defaultalignment < alignment};
18171820
if (alignedadjustment)
@@ -1835,9 +1838,10 @@ inline constexpr void *status_allocator_pointer_aligned_impl(typename alloc::han
18351838
}
18361839

18371840
template <typename alloc, bool zero>
1838-
requires(::fast_io::generic_allocator_adapter<alloc>::has_native_handle_allocate)
18391841
inline constexpr ::fast_io::allocation_least_result status_allocator_pointer_aligned_impl(typename alloc::handle_type handle, ::std::size_t alignment, ::std::size_t n) noexcept
18401842
{
1843+
static_assert(::fast_io::generic_allocator_adapter<alloc>::has_native_handle_allocate);
1844+
18411845
constexpr ::std::size_t defaultalignment{::fast_io::details::calculate_default_alignment<alloc>()};
18421846
bool const alignedadjustment{defaultalignment < alignment};
18431847
if (alignedadjustment)

0 commit comments

Comments
 (0)