21 #ifndef __TBB_range_iterator_H 22 #define __TBB_range_iterator_H 24 #include "../tbb_stddef.h" 26 #if __TBB_CPP11_STD_BEGIN_END_PRESENT && __TBB_CPP11_AUTO_PRESENT && __TBB_CPP11_DECLTYPE_PRESENT 34 #if __TBB_CPP11_STD_BEGIN_END_PRESENT && __TBB_CPP11_AUTO_PRESENT && __TBB_CPP11_DECLTYPE_PRESENT 37 template<
typename Container>
38 auto first(Container& c)-> decltype(begin(c)) {
return begin(c);}
40 template<
typename Container>
41 auto first(
const Container& c)-> decltype(begin(c)) {
return begin(c);}
43 template<
typename Container>
44 auto last(Container& c)-> decltype(begin(c)) {
return end(c);}
46 template<
typename Container>
47 auto last(
const Container& c)-> decltype(begin(c)) {
return end(c);}
49 template<
typename Container>
50 typename Container::iterator first(Container& c) {
return c.begin();}
52 template<
typename Container>
53 typename Container::const_iterator first(
const Container& c) {
return c.begin();}
55 template<
typename Container>
56 typename Container::iterator last(Container& c) {
return c.end();}
58 template<
typename Container>
59 typename Container::const_iterator last(
const Container& c) {
return c.end();}
62 template<
typename T,
size_t size>
63 T* first(T (&arr) [size]) {
return arr;}
65 template<
typename T,
size_t size>
66 T* last(T (&arr) [size]) {
return arr + size;}
70 #endif // __TBB_range_iterator_H Definition: _flow_graph_async_msg_impl.h:32
The namespace tbb contains all components of the library.
Definition: parallel_for.h:44