Files
boost_range/doc/reference/ranges/irange.qbk
Neil Groves b0d1db7c2e Boost.RangeEx merged into Boost.Range
[SVN r60897]
2010-03-28 16:08:35 +00:00

36 lines
983 B
Plaintext

[section:irange irange]
[heading Prototype]
``
template<class Integer>
integer_range< range_detail::integer_iterator<Integer> >
irange(Integer first, Integer last);
template<class Integer, class StepSize>
integer_range< range_detail::integer_iterator_with_step<Integer, StepSize> >
irange(Integer first, Integer last, StepSize step_size);
``
[heading Description]
`irange` is a function to generate an Integer Range.
`irange` allows treating integers as a model of the __random_access_range__ Concept. It should be noted that the `first` and `last` parameters denoted a half-open range.
[heading Definition]
Defined in the header file `boost/range/irange.hpp`
[heading Requirements]
# `Integer` is a model of the `Integer` Concept.
# `StepSize` is a model of the `SignedInteger` Concept.
[heading Complexity]
Constant. Since this function generates a new range the most significant performance cost is incurred through the iteration of the generated range.
[endsect]