Index: boost/range/iterator_range_core.hpp =================================================================== --- boost/range/iterator_range_core.hpp (revision 83595) +++ boost/range/iterator_range_core.hpp (working copy) @@ -21,7 +21,9 @@ #include #include #include +#include #include +#include #include #include #include @@ -167,7 +169,8 @@ private: // for return value of operator()() typedef BOOST_DEDUCED_TYPENAME - boost::mpl::if_< boost::is_abstract, + boost::mpl::if_< boost::mpl::or_< boost::is_abstract< value_type >, + boost::is_array< value_type > >, reference, value_type >::type abstract_value_type; public: Index: libs/range/test/iterator_range.cpp =================================================================== --- libs/range/test/iterator_range.cpp (revision 83595) +++ libs/range/test/iterator_range.cpp (working copy) @@ -101,6 +101,11 @@ BOOST_CHECK( rrr == str ); check_reference_type(); + + // Check that an iterator range can be instantiated with + // a pointer to an array as an iterator. + int arr[2][2]; + boost::make_iterator_range(arr, arr + 2); } namespace iterator_range_test_detail