I create a Visual Studio 2013 update 1 VC++ Win32 Console Application project, and copy the example from
boost_1_55_0\libs\geometry\doc\html\geometry\spatial_indexes\rtree_examples\quick_start.html to a file(delete all codes first),
set Precompiled Headers to Not Using Precompiled Headers, then build. But build failed.
I change the platform toolset from Visual Studio 2013 (v120) to Visual Studio 2010 (v100), then build successfully.
Is it a bug ?
Visual Studio 2013 (v120) error message:
1>------ Rebuild All started: Project: ConsoleApplication1, Configuration: Debug Win32 ------
1> ConsoleApplication1.cpp
1>c:\users\qiaozhiqiang\documents\visual studio 2013\projects\consoleapplication1\consoleapplication1\consoleapplication1.cpp(30): warning C4244: 'argument' : conversion from 'unsigned int' to 'const float', possible loss of data
1>d:\qzq\boost_1_55_0\boost\intrusive\detail\has_member_function_callable_with.hpp(200): error C2228: left of '.select_on_container_copy_construction' must have class/struct/union
1> type is 'boost::move_detail::add_rvalue_reference<U>::type'
1> d:\qzq\boost_1_55_0\boost\intrusive\detail\has_member_function_callable_with.hpp(276) : see reference to class template instantiation 'boost::container::container_detail::has_member_function_callable_with_select_on_container_copy_construction_impl<Fun,true,>' being compiled
1> with
1> [
1> Fun=std::allocator<boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>
1> ]
1> d:\qzq\boost_1_55_0\boost\container\allocator_traits.hpp(262) : see reference to class template instantiation 'boost::container::container_detail::has_member_function_callable_with_select_on_container_copy_construction<const Alloc,>' being compiled
1> with
1> [
1> Alloc=std::allocator<boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\detail\rtree\node\node_d_mem_dynamic.hpp(257) : see reference to class template instantiation 'boost::container::allocator_traits<AllocNode>' being compiled
1> with
1> [
1> AllocNode=std::allocator<boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\detail\rtree\node\node_d_mem_dynamic.hpp(320) : see reference to function template instantiation 'BaseNodePtr boost::geometry::index::detail::rtree::create_dynamic_node<BaseNodePtr,boost::geometry::index::detail::rtree::dynamic_leaf<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>::apply<std::allocator<_Other>>(AllocNode &)' being compiled
1> with
1> [
1> BaseNodePtr=boost::geometry::index::detail::rtree::dynamic_node<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag> *
1> , Value=std::pair<box,unsigned int>
1> , Parameters=boost::geometry::index::quadratic<16,4>
1> , Box=boost::geometry::model::box<point>
1> , Allocators=boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> , _Other=boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> , AllocNode=std::allocator<boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\detail\rtree\node\node_d_mem_dynamic.hpp(320) : see reference to function template instantiation 'BaseNodePtr boost::geometry::index::detail::rtree::create_dynamic_node<BaseNodePtr,boost::geometry::index::detail::rtree::dynamic_leaf<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>::apply<std::allocator<_Other>>(AllocNode &)' being compiled
1> with
1> [
1> BaseNodePtr=boost::geometry::index::detail::rtree::dynamic_node<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag> *
1> , Value=std::pair<box,unsigned int>
1> , Parameters=boost::geometry::index::quadratic<16,4>
1> , Box=boost::geometry::model::box<point>
1> , Allocators=boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> , _Other=boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> , AllocNode=std::allocator<boost::geometry::index::detail::rtree::dynamic_leaf<std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\detail\rtree\node\node_d_mem_dynamic.hpp(316) : while compiling class template member function 'boost::geometry::index::detail::rtree::dynamic_node<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag> *boost::geometry::index::detail::rtree::create_node<Allocators,boost::geometry::index::detail::rtree::dynamic_leaf<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>::apply(Allocators &)'
1> with
1> [
1> Value=std::pair<box,unsigned int>
1> , Parameters=boost::geometry::index::quadratic<16,4>
1> , Box=boost::geometry::model::box<point>
1> , Allocators=boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\rtree.hpp(1267) : see reference to function template instantiation 'boost::geometry::index::detail::rtree::dynamic_node<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag> *boost::geometry::index::detail::rtree::create_node<Allocators,boost::geometry::index::detail::rtree::dynamic_leaf<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>::apply(Allocators &)' being compiled
1> with
1> [
1> Value=std::pair<box,unsigned int>
1> , Parameters=boost::geometry::index::quadratic<16,4>
1> , Box=boost::geometry::model::box<point>
1> , Allocators=boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\rtree.hpp(1267) : see reference to class template instantiation 'boost::geometry::index::detail::rtree::create_node<boost::geometry::index::detail::rtree::allocators<std::allocator<Value>,Value,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>,boost::geometry::index::detail::rtree::dynamic_leaf<Value,Parameters,Box,Allocators,boost::geometry::index::detail::rtree::node_d_mem_static_tag>>' being compiled
1> with
1> [
1> Value=value
1> , Parameters=boost::geometry::index::quadratic<16,4>
1> , Box=boost::geometry::model::box<point>
1> , Allocators=boost::geometry::index::detail::rtree::allocators<std::allocator<value>,std::pair<box,unsigned int>,boost::geometry::index::quadratic<16,4>,boost::geometry::model::box<point>,boost::geometry::index::detail::rtree::node_d_mem_static_tag>
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\rtree.hpp(1264) : while compiling class template member function 'void boost::geometry::index::rtree<value,boost::geometry::index::quadratic<16,4>,boost::geometry::index::indexable<Value>,boost::geometry::index::equal_to<Value>,std::allocator<Value>>::raw_create(void)'
1> with
1> [
1> Value=value
1> ]
1> d:\qzq\boost_1_55_0\boost\geometry\index\rtree.hpp(544) : see reference to function template instantiation 'void boost::geometry::index::rtree<value,boost::geometry::index::quadratic<16,4>,boost::geometry::index::indexable<Value>,boost::geometry::index::equal_to<Value>,std::allocator<Value>>::raw_create(void)' being compiled
1> with
1> [
1> Value=value
1> ]
1> c:\users\qiaozhiqiang\documents\visual studio 2013\projects\consoleapplication1\consoleapplication1\consoleapplication1.cpp(24) : see reference to class template instantiation 'boost::geometry::index::rtree<value,boost::geometry::index::quadratic<16,4>,boost::geometry::index::indexable<Value>,boost::geometry::index::equal_to<Value>,std::allocator<Value>>' being compiled
1> with
1> [
1> Value=value
1> ]
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
consoleapplication1.cpp, line 24 is:
bgi::rtree< value, bgi::quadratic<16> > rtree;