usability tweaks: functions that return iterators return them as *const* to allow chaining when the recipient function expects a reference (e.g. foo(Iter&) )

[SVN r35940]
This commit is contained in:
Joel de Guzman
2006-11-09 01:48:46 +00:00
parent 4b061d2716
commit c621277c07
7 changed files with 11 additions and 11 deletions

View File

@ -75,14 +75,14 @@ namespace boost { namespace fusion
}
template <int N, typename Iterator>
inline typename result_of::advance_c<Iterator, N>::type
inline typename result_of::advance_c<Iterator, N>::type const
advance_c(Iterator const& i)
{
return result_of::advance_c<Iterator, N>::call(i);
}
template<typename N, typename Iterator>
inline typename result_of::advance<Iterator, N>::type
inline typename result_of::advance<Iterator, N>::type const
advance(Iterator const& i)
{
return result_of::advance<Iterator, N>::call(i);

View File

@ -54,7 +54,7 @@ namespace boost { namespace fusion
}
template <typename Iterator>
typename result_of::next<Iterator>::type
typename result_of::next<Iterator>::type const
next(Iterator const& i)
{
return result_of::next<Iterator>::call(i);

View File

@ -54,7 +54,7 @@ namespace boost { namespace fusion
}
template <typename Iterator>
typename result_of::prior<Iterator>::type
typename result_of::prior<Iterator>::type const
prior(Iterator const& i)
{
return result_of::prior<Iterator>::call(i);