Skip to content

Commit

Permalink
volatile and contiguous_iterator do not mix
Browse files Browse the repository at this point in the history
  • Loading branch information
miscco committed May 30, 2020
1 parent a7fa5a8 commit 5fa7623
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion stl/inc/xutility
Original file line number Diff line number Diff line change
Expand Up @@ -4124,7 +4124,7 @@ _INLINE_VAR constexpr bool _Can_assign_elements<_Source, _Dest, _Memcopy_cat::_M
// _Memcopy_is_safe<_Iter1, _Iter2> reports whether we can activate the memcopy optimization for arbitrary iterators.
// It ignores top-level constness on the iterators and on the elements.
template <class _Iter1, class _Iter2, _Memcopy_cat _Cat>
_INLINE_VAR constexpr bool _Memcopy_is_safe_helper = _Iterators_are_contiguous<_Iter1, _Iter2> //
_INLINE_VAR constexpr bool _Memcopy_is_safe_helper = conjunction_v<is_pointer<_Iter1>, is_pointer<_Iter2>> //
&& _Can_assign_elements<remove_reference_t<_Iter_ref_t<_Iter1>>, remove_reference_t<_Iter_ref_t<_Iter2>>, _Cat> //
&& _Can_memcopy_elements<remove_cv_t<remove_reference_t<_Iter_ref_t<_Iter1>>>,
remove_cv_t<remove_reference_t<_Iter_ref_t<_Iter2>>>, _Cat>;
Expand Down

0 comments on commit 5fa7623

Please sign in to comment.