tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
rotate_copy.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSL-1.0
2
3#ifndef TETL_ALGORITHM_ROTATE_COPY_HPP
4#define TETL_ALGORITHM_ROTATE_COPY_HPP
5
7
8namespace etl {
9
15template <typename ForwardIt, typename OutputIt>
16constexpr auto rotate_copy(ForwardIt first, ForwardIt nFirst, ForwardIt last, OutputIt destination) -> OutputIt
17{
18 destination = etl::copy(nFirst, last, destination);
19 return etl::copy(first, nFirst, destination);
20}
21
22} // namespace etl
23
24#endif // TETL_ALGORITHM_ROTATE_COPY_HPP
constexpr auto rotate_copy(ForwardIt first, ForwardIt nFirst, ForwardIt last, OutputIt destination) -> OutputIt
Copies the elements from the range [first, last), to another range beginning at destination in such a...
Definition rotate_copy.hpp:16
constexpr auto copy(InputIt first, InputIt last, OutputIt destination) -> OutputIt
Copies the elements in the range, defined by [first, last), to another range beginning at destination...
Definition copy.hpp:18
Definition adjacent_find.hpp:8