stlab 2.3.0
Modern, modular C++ algorithms, data structures, and concurrency primitives
Loading...
Searching...
No Matches
concepts.hpp
Go to the documentation of this file.
1#ifndef STLAB_ITERATOR_CONCEPTS_HPP
2#define STLAB_ITERATOR_CONCEPTS_HPP
3
7
8#define STLAB_CONCEPT(x) STLAB_PRIVATE_CONCEPT_##x
9
10#if __cpp_has_concepts
11
12#include <iterator>
13
14#include <stlab/config.hpp>
16
17namespace stlab {
18STLAB_VERSION_NAMESPACE_BEGIN()
19
20
25
26template <class I>
27concept forward_node_iterator = std::forward_iterator<I> && requires(I i) {
29};
30
32
33STLAB_VERSION_NAMESPACE_END()
34} // namespace stlab
35
36#define STLAB_PRIVATE_CONCEPT_FORWARD_NODE_ITERATOR stlab::forward_node_iterator
37
38#else
39
40#define STLAB_PRIVATE_CONCEPT_FORWARD_NODE_ITERATOR typename
41
42#endif
43
44#endif
Definition concepts.hpp:27
void set_next(const I &x, const I &y)
Sets the successor of the node referenced by x to y (via set_next_fn<I>).
Definition set_next.hpp:41
Definition reverse.hpp:28
Intrusive forward/bidirectional iterator helpers (set_next, splice, skip).