
Thank you for your reply.
1 The reason for the problem you suggest had been considered in the
file
On Sat, 22 May 2010, smallpang smallpang wrote:
dear everyone
I want to construct multicast tree base on the network topology generated
The source code below can run without error, and have the right output: The file is open! m:28 n:10
But when I add the algrithom dijkstra_shortest_paths. The error messages show as below: Description Resource Path Location Type no matching function for call to ‘num_vertices(Graph* const&)’ MulticastTree2 line 190, external location: /usr/include/boost/graph/dijkstra_shortest_paths.hpp C/C++ Problem Description Resource Path Location Type no matching function for call to ‘out_edges(Vertex*&, Graph* const&)’ MulticastTree2 line 76, external location: /usr/include/boost/graph/breadth_first_search.hpp C/C++ Problem Description Resource Path Location Type no matching function for call to ‘vertices(Graph* const&)’ MulticastTree2
external location: /usr/include/boost/graph/dijkstra_shortest_paths.hpp C/C++ Problem
I find the num_vertices\out_edges\vertices are redefined in the stanford_graph.hpp. So I change the order of the include files as below: #include
#include The errors above disappear, and New errors come up: Description Resource Path Location Type ‘g’ was not declared in this scope MulticastTree2 line 408, external location: /usr/include/boost/graph/named_function_params.hpp C/C++ Problem Description Resource Path Location Type ‘t’ was not declared in this scope MulticastTree2 line 408, external location: /usr/include/boost/graph/named_function_params.hpp C/C++ Problem Description Resource Path Location Type ‘u’ was not declared in this scope MulticastTree2 line 463, external location: /usr/include/boost/pending/relaxed_heap.hpp C/C++ Problem Description Resource Path Location Type expected ‘,’ or ‘...’ before ‘.’ token MulticastTree2 line 402, external location: /usr/include/boost/graph/named_function_params.hpp C/C++ Problem Description Resource Path Location Type expected initializer before ‘.’ token MulticastTree2 line 462, external location: /usr/include/boost/pending/relaxed_heap.hpp C/C++ Problem
It's confusing for me, can you tell me what's the problem is and any way i can try to solve the problems above.
It looks like (for the second include order) that many places in BGL use Graph as a template parameter name, so that is likely the problem there;
by the stanford graph. line 375, please use the first ordering. For the first one, that may be fixable by using "const Graph*" as the type of your graph object (and changing the rest of the Graph*'s to that as well). See if that changes any of the errors.
-- Jeremiah Willcock _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users