mirror of
https://github.com/boostorg/utility.git
synced 2025-05-09 15:04:00 +00:00
updated for named parameters
[SVN r11566]
This commit is contained in:
parent
95197f427c
commit
3ca4a33a65
@ -4,7 +4,9 @@
|
|||||||
// "as is" without express or implied warranty, and with no claim as
|
// "as is" without express or implied warranty, and with no claim as
|
||||||
// to its suitability for any purpose.
|
// to its suitability for any purpose.
|
||||||
|
|
||||||
// 8 Mar 2001 Jeremy Siek
|
// 04 Nov 2001 Jeremy Siek
|
||||||
|
// Updated with respect to new named parameter interface.
|
||||||
|
// 08 Mar 2001 Jeremy Siek
|
||||||
// Initial checkin.
|
// Initial checkin.
|
||||||
|
|
||||||
#include <boost/iterator_adaptors.hpp>
|
#include <boost/iterator_adaptors.hpp>
|
||||||
@ -26,9 +28,8 @@ main()
|
|||||||
|
|
||||||
{
|
{
|
||||||
typedef boost::iterator_adaptor<my_iter, boost::default_iterator_policies,
|
typedef boost::iterator_adaptor<my_iter, boost::default_iterator_policies,
|
||||||
boost::iterator_traits_generator
|
boost::reference_is<dummyT>,
|
||||||
::reference<dummyT>
|
boost::iterator_category_is<std::input_iterator_tag> > iter_type;
|
||||||
::iterator_category<std::input_iterator_tag> > iter_type;
|
|
||||||
|
|
||||||
BOOST_STATIC_ASSERT((boost::is_same<iter_type::iterator_category*,
|
BOOST_STATIC_ASSERT((boost::is_same<iter_type::iterator_category*,
|
||||||
std::input_iterator_tag*>::value));
|
std::input_iterator_tag*>::value));
|
||||||
@ -42,12 +43,11 @@ main()
|
|||||||
{
|
{
|
||||||
typedef boost::iterator_adaptor<dummyT*,
|
typedef boost::iterator_adaptor<dummyT*,
|
||||||
boost::default_iterator_policies,
|
boost::default_iterator_policies,
|
||||||
boost::iterator_traits_generator
|
boost::value_type_is<dummyT>,
|
||||||
::value_type<dummyT>
|
boost::reference_is<const dummyT&>,
|
||||||
::reference<const dummyT&>
|
boost::pointer_is<const dummyT*> ,
|
||||||
::pointer<const dummyT*>
|
boost::iterator_category_is<std::forward_iterator_tag>,
|
||||||
::iterator_category<std::forward_iterator_tag>
|
boost::difference_type_is<std::ptrdiff_t> > adaptor_type;
|
||||||
::difference_type<std::ptrdiff_t> > adaptor_type;
|
|
||||||
|
|
||||||
adaptor_type i(array);
|
adaptor_type i(array);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user