
On Fri, Oct 30, 2009 at 8:46 AM, Jeremiah Willcock <jewillco@osl.iu.edu> wrote:
On Fri, 30 Oct 2009, Nil Geisweiller wrote:
It is weird, I tried with 2 settings
Ubuntu 9.04, gcc-4.3.3, boost 1.40 Ubuntu 9.10, gcc-4.4.1, boost 1.40
And I get the compiling errors:
/usr/include/boost/property_map/property_map.hpp: In instantiation of ‘boost::property_traits<int>’: /usr/include/boost/graph/two_bit_color_map.hpp:46: instantiated from ‘boost::two_bit_color_map<int>’ /home/a-lin/Sources/test/test.cpp:10: instantiated from here /usr/include/boost/property_map/property_map.hpp:31: error: ‘int’ is not a class, struct, or union type /usr/include/boost/property_map/property_map.hpp:32: error: ‘int’ is not a class, struct, or union type /usr/include/boost/property_map/property_map.hpp:33: error: ‘int’ is not a class, struct, or union type /usr/include/boost/property_map/property_map.hpp:34: error: ‘int’ is not a class, struct, or union type
Has anyone experienced problem too?
Thanks Nil
I'm surprised that this did not happen in earlier Boost versions.
yes it does not happen in boost 1.35. I've carefully compared some files from the graph library between 1.35 and 1.40 and I don't see anything suspect added in 1.40. So like you I am really surprised.
I think the problem is that two components are using exactly the same function name, and Boost.Graph's version (it's not in strong_components.hpp, just included from there) does not accept the template argument you are giving it. As it appears that there is no member or other function to get the value out of a variant, it might be hard to avoid this error. The version of get() in two_bit_color_map.hpp does not require any explicitly specified template arguments, but that is not the version you want anyway.
What do you think is the right way to fix that? Thanks Nil