forked from boostorg/range
[boost][range] - Resolution of Trac ticket 4355. Made the naming of the returned types from range adaptors consistent and documented.
[SVN r67420]
This commit is contained in:
@ -19,7 +19,7 @@ namespace boost
|
||||
namespace range_detail
|
||||
{
|
||||
template< class R >
|
||||
struct indirect_range :
|
||||
struct indirected_range :
|
||||
public boost::iterator_range<
|
||||
boost::indirect_iterator<
|
||||
BOOST_DEDUCED_TYPENAME range_iterator<R>::type
|
||||
@ -35,7 +35,7 @@ namespace boost
|
||||
base;
|
||||
|
||||
public:
|
||||
explicit indirect_range( R& r )
|
||||
explicit indirected_range( R& r )
|
||||
: base( r )
|
||||
{ }
|
||||
};
|
||||
@ -43,22 +43,22 @@ namespace boost
|
||||
struct indirect_forwarder {};
|
||||
|
||||
template< class InputRng >
|
||||
inline indirect_range<InputRng>
|
||||
inline indirected_range<InputRng>
|
||||
operator|( InputRng& r, indirect_forwarder )
|
||||
{
|
||||
return indirect_range<InputRng>( r );
|
||||
return indirected_range<InputRng>( r );
|
||||
}
|
||||
|
||||
template< class InputRng >
|
||||
inline indirect_range<const InputRng>
|
||||
inline indirected_range<const InputRng>
|
||||
operator|( const InputRng& r, indirect_forwarder )
|
||||
{
|
||||
return indirect_range<const InputRng>( r );
|
||||
return indirected_range<const InputRng>( r );
|
||||
}
|
||||
|
||||
} // 'range_detail'
|
||||
|
||||
using range_detail::indirect_range;
|
||||
using range_detail::indirected_range;
|
||||
|
||||
namespace adaptors
|
||||
{
|
||||
@ -69,17 +69,17 @@ namespace boost
|
||||
}
|
||||
|
||||
template<class InputRange>
|
||||
inline indirect_range<InputRange>
|
||||
inline indirected_range<InputRange>
|
||||
indirect(InputRange& rng)
|
||||
{
|
||||
return indirect_range<InputRange>(rng);
|
||||
return indirected_range<InputRange>(rng);
|
||||
}
|
||||
|
||||
template<class InputRange>
|
||||
inline indirect_range<const InputRange>
|
||||
inline indirected_range<const InputRange>
|
||||
indirect(const InputRange& rng)
|
||||
{
|
||||
return indirect_range<const InputRange>(rng);
|
||||
return indirected_range<const InputRange>(rng);
|
||||
}
|
||||
} // 'adaptors'
|
||||
|
||||
|
Reference in New Issue
Block a user