id summary reporter owner description type status milestone component version severity resolution keywords cc 6742 C4789 warning using boost range on visual 2010 benjamint@… Neil Groves "Hello, I am compiling under Windows XP using Visual Studio 2010. When I use boost::range, I have some strange compilation warning ""warning C4789: destination of memory copy is too small"". Here is a small unit test that reproduces this warning: {{{ #define BOOST_TEST_MODULE boost_range_c4789_test #include #include #include #include #include #include #include #include /** \deftestgroup{boost_range_c4789_test} \brief Test a spurious C4789 MSVC warning that happens with boost range @{ **/ struct FooType { double a,b; }; //----------------------------------------------------------------------------- /** \testdesc The actual test **/ BOOST_AUTO_TEST_CASE( boost_range_c4789_bug ) { using namespace boost::phoenix::arg_names; using namespace boost::adaptors; FooType foo; foo.a = 2.; foo.b = -4.; size_t numelem = 10; std::vector foovec(numelem,foo); std::vector barvec; boost::push_back( barvec, foovec | transformed( (&arg1)->*& FooType::a ) ); BOOST_CHECK( barvec == std::vector(numelem,foo.a) ); } ///@} }}} Thanks for your help, Benjamin. " Bugs closed To Be Determined range Boost 1.47.0 Problem fixed range visual C4789