tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
legacy_iterator.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSL-1.0
2// SPDX-FileCopyrightText: Copyright (C) 2024 Tobias Hienzsch
3
4#ifndef TETL_ITERATOR_LEGACY_ITERATOR_HPP
5#define TETL_ITERATOR_LEGACY_ITERATOR_HPP
6
7#include <etl/_concepts/copyable.hpp>
8#include <etl/_concepts/referenceable.hpp>
9#include <etl/_concepts/same_as.hpp>
10
11namespace etl {
12
13/// \note Non-standard extension
14/// \headerfile etl/iterator.hpp
15/// \ingroup iterator
16template <typename Iter>
17concept legacy_iterator = requires(Iter i) {
18 { *i } -> etl::referenceable;
19 { ++i } -> etl::same_as<Iter&>;
20 { *i++ } -> etl::referenceable;
21} and etl::copyable<Iter>;
22
23} // namespace etl
24
25#endif // TETL_ITERATOR_LEGACY_ITERATOR_HPP
Definition adjacent_find.hpp:9