We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6854704 commit 600f969Copy full SHA for 600f969
include/cpp-sort/detail/move.h
@@ -1,5 +1,5 @@
1
/*
2
- * Copyright (c) 2019-2022 Morwenn
+ * Copyright (c) 2019-2025 Morwenn
3
* SPDX-License-Identifier: MIT
4
*/
5
#ifndef CPPSORT_DETAIL_MOVE_H_
@@ -102,8 +102,9 @@ namespace detail
102
-> T*
103
{
104
using truth_type = std::integral_constant<bool,
105
- std::is_trivial<value_type_t<InputIterator>>::value &&
106
- std::is_trivial<T>::value
+ std::is_trivially_copyable<value_type_t<InputIterator>>::value &&
+ std::is_trivially_copyable<T>::value &&
107
+ sizeof(T) == sizeof(value_type_t<InputIterator>)
108
>;
109
return uninitialized_move_impl(truth_type{}, std::move(first), std::move(last),
110
std::move(result), destroyer);
0 commit comments