[cvs] Conflict between Boost.Graph and Boost.String_algo

Hi Everyone, It seems like there's a problem with the following include sequence: #include <boost/graph/adjacency_list.hpp> #include <boost/graph/graph_utility.hpp> #include <boost/graph/visitors.hpp> #include <boost/graph/breadth_first_search.hpp> #include <boost/algorithm/string.hpp> GCC 4.1.2 complains that boost::contains and boost::all is already defined. The compiler complains that boost/boost/algorithm/predicate.hpp is trying to define 'contains' and 'all' which apparently is already defined somewhere in the Boost.Graph headers. I would submit a patch, but I didn't know whether to touch Boost.Graph or String Algorightms and how. (Using latest CVS checkout May 30) HTH -- Dean Michael C. Berris http://cplusplus-soup.blogspot.com/ mikhailberis AT gmail DOT com +63 928 7291459

Hi, I have checked it using vc8.0 (the only compiler I have at hand right now) and I haven't found any conflicts. Simple file search also haven't revealed anything with these names in Boost.Graph. Can you post a pointer to conflicting names in the Boost.Graph? If there is a conflict, I assume that either Boost.Graph of Boost.string_algo version will have to be renamed. I can argue only on behalf to string_algo. These two are first-order algorithms and changing their names will break a lots of user code. Regards, Pavol. Dean Michael Berris wrote:
Hi Everyone,
It seems like there's a problem with the following include sequence:
#include <boost/graph/adjacency_list.hpp> #include <boost/graph/graph_utility.hpp> #include <boost/graph/visitors.hpp> #include <boost/graph/breadth_first_search.hpp> #include <boost/algorithm/string.hpp>
GCC 4.1.2 complains that boost::contains and boost::all is already defined. The compiler complains that boost/boost/algorithm/predicate.hpp is trying to define 'contains' and 'all' which apparently is already defined somewhere in the Boost.Graph headers.
I would submit a patch, but I didn't know whether to touch Boost.Graph or String Algorightms and how.
(Using latest CVS checkout May 30)
HTH

On May 30, 2007, at 10:57 AM, Pavol Droba wrote:
Can you post a pointer to conflicting names in the Boost.Graph?
They're in boost/detail/algorithm.hpp, which is used by Boost.Graph.
I can argue only on behalf to string_algo. These two are first-order algorithms and changing their names will break a lots of user code.
I could argue that the versions that Boost.Graph is using have been there since 2001, but I won't :) Since it's a detail header, users shouldn't be relying on it anyway. I'll prepare a patch to rename (or put into boost::detail) the problematic algorithms, as necessary. Thanks, Dean, for reporting this problem. Could you file a bug report in the Boost Trac at http://svn.boost.org describing the problem? Please assign it to me. - Doug

On May 30, 2007, at 11:07 AM, Douglas Gregor wrote:
Thanks, Dean, for reporting this problem. Could you file a bug report in the Boost Trac at http://svn.boost.org describing the problem? Please assign it to me.
Nevermind, it's fixed in Boost CVS. - Doug

Hi Doug! On 5/31/07, Douglas Gregor <doug.gregor@gmail.com> wrote:
On May 30, 2007, at 11:07 AM, Douglas Gregor wrote:
Thanks, Dean, for reporting this problem. Could you file a bug report in the Boost Trac at http://svn.boost.org describing the problem? Please assign it to me.
Nevermind, it's fixed in Boost CVS.
Sorry it took a while... I'll go ahead and try it again. Thanks as well Doug! -- Dean Michael C. Berris http://cplusplus-soup.blogspot.com/ mikhailberis AT gmail DOT com +63 928 7291459
participants (3)
-
Dean Michael Berris
-
Douglas Gregor
-
Pavol Droba