Last change
on this file since 44 was
44,
checked in by cholod, 12 years ago
|
Load NEMO_TMP into vendor/nemo/current.
|
File size:
1.1 KB
|
Line | |
---|
1 | // Boost.Range library |
---|
2 | // |
---|
3 | // Copyright Neil Groves 2008. Use, modification and |
---|
4 | // distribution is subject to the Boost Software Licence, Version |
---|
5 | // 1.0. (See accompanying file LICENSE_1_0.txt or copy at |
---|
6 | // http://www.boost.org/LICENSE_1_0.txt |
---|
7 | // |
---|
8 | // For more information, see http://www.boost.org/libs/range |
---|
9 | // |
---|
10 | |
---|
11 | #ifndef BOOST_RANGE_ISTREAM_RANGE_HPP_INCLUDED |
---|
12 | #define BOOST_RANGE_ISTREAM_RANGE_HPP_INCLUDED |
---|
13 | |
---|
14 | /*! |
---|
15 | * \file istream_range.hpp |
---|
16 | */ |
---|
17 | |
---|
18 | #include <iterator> |
---|
19 | #include <istream> |
---|
20 | #include <boost/config.hpp> |
---|
21 | #include <boost/range/iterator_range.hpp> |
---|
22 | |
---|
23 | namespace boost |
---|
24 | { |
---|
25 | namespace range |
---|
26 | { |
---|
27 | template<class Type, class Elem, class Traits> inline |
---|
28 | iterator_range<std::istream_iterator<Type, Elem, Traits> > |
---|
29 | istream_range(std::basic_istream<Elem, Traits>& in) |
---|
30 | { |
---|
31 | return iterator_range<std::istream_iterator<Type, Elem, Traits> >( |
---|
32 | std::istream_iterator<Type>(in), |
---|
33 | std::istream_iterator<Type>()); |
---|
34 | } |
---|
35 | } // namespace range |
---|
36 | using range::istream_range; |
---|
37 | } // namespace boost |
---|
38 | |
---|
39 | #endif // include guard |
---|
Note: See
TracBrowser
for help on using the repository browser.