Update of /cvsroot/boost/boost/boost/graph
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv8095/graph

Modified Files:
        graph_concepts.hpp 
Log Message:
Deal with GCC problems in updated concepts library

Index: graph_concepts.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/graph/graph_concepts.hpp,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -d -r1.43 -r1.44
--- graph_concepts.hpp  2 May 2006 15:06:06 -0000       1.43
+++ graph_concepts.hpp  27 Jun 2006 15:01:14 -0000      1.44
@@ -22,6 +22,26 @@
 
 namespace boost
 {
+// dwa 2003/7/11 -- This clearly shouldn't be necessary, but if
+// you want to use vector_as_graph, it is!  I'm sure the graph
+// library leaves these out all over the place.  Probably a
+// redesign involving specializing a template with a static
+// member function is in order :(
+//
+// It is needed in order to allow us to write using boost::vertices as
+// needed for ADL when using vector_as_graph below.
+#if !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP)            \
+ && !BOOST_WORKAROUND(__GNUC__, <= 2)                       \
+ && !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
+# define BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK
+#endif 
+
+#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK
+template <class T>
+typename T::ThereReallyIsNoMemberByThisNameInT vertices(T const&);
+#endif      
+
+  namespace concepts {
   BOOST_concept(MultiPassInputIterator,(T)) {
     ~MultiPassInputIterator() {
         BOOST_CONCEPT_ASSERT((InputIterator<T>));
@@ -41,6 +61,9 @@
       ~Graph()
       {
           BOOST_CONCEPT_ASSERT((DefaultConstructible<vertex_descriptor>));
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+      IncidenceGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
           BOOST_CONCEPT_ASSERT((EqualityComparable<vertex_descriptor>));
           BOOST_CONCEPT_ASSERT((Assignable<vertex_descriptor>));
       }
@@ -77,6 +100,9 @@
           const_constraints(g);
       }
       void const_constraints(const G& cg) {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    BidirectionalGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
           p = out_edges(u, cg);
           n = out_degree(u, cg);
           e = *p.first;
@@ -106,6 +132,9 @@
       n = in_degree(v, g);
       e = *p.first;
       const_constraints(g);
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    AdjacencyGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     }
     void const_constraints(const G& cg) {
       p = in_edges(v, cg);
@@ -143,31 +172,15 @@
     G g;
   };
 
-// dwa 2003/7/11 -- This clearly shouldn't be necessary, but if
-// you want to use vector_as_graph, it is!  I'm sure the graph
-// library leaves these out all over the place.  Probably a
-// redesign involving specializing a template with a static
-// member function is in order :(
-//
-// It is needed in order to allow us to write using boost::vertices as
-// needed for ADL when using vector_as_graph below.
-#if !defined(BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP)            \
- && !BOOST_WORKAROUND(__GNUC__, <= 2)                       \
- && !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x564))
-# define BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK
-#endif 
-
-#ifdef BOOST_VECTOR_AS_GRAPH_GRAPH_ADL_HACK
-template <class T>
-typename T::ThereReallyIsNoMemberByThisNameInT vertices(T const&);
-#endif      
-
   BOOST_concept(VertexListGraph,(G))
     : Graph<G>
   {
     typedef typename graph_traits<G>::vertex_iterator vertex_iterator;
     typedef typename graph_traits<G>::vertices_size_type vertices_size_type;
     typedef typename graph_traits<G>::traversal_category
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    VertexListGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
       traversal_category;
     ~VertexListGraph() {
       BOOST_CONCEPT_ASSERT((MultiPassInputIterator<vertex_iterator>));
@@ -213,6 +226,9 @@
     typedef typename graph_traits<G>::edge_iterator edge_iterator;
     typedef typename graph_traits<G>::edges_size_type edges_size_type;
     typedef typename graph_traits<G>::traversal_category
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    EdgeListGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
       traversal_category;
     ~EdgeListGraph() {
       BOOST_CONCEPT_ASSERT((MultiPassInputIterator<edge_iterator>));
@@ -245,7 +261,11 @@
   BOOST_concept(VertexAndEdgeListGraph,(G))
     : VertexListGraph<G>
     , EdgeListGraph<G>
-  {};
+  {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    VertexAndEdgeListGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
+  };
 
   // Where to put the requirement for this constructor?
   //      G g(n_vertices);
@@ -255,6 +275,9 @@
   BOOST_concept(EdgeMutableGraph,(G))
   {
     typedef typename graph_traits<G>::edge_descriptor edge_descriptor;
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    EdgeMutableGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~EdgeMutableGraph() {
       p = add_edge(u, v, g);
       remove_edge(u, v, g);
@@ -269,6 +292,9 @@
 
   BOOST_concept(VertexMutableGraph,(G))
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    VertexMutableGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~VertexMutableGraph() {
       v = add_vertex(g);
       remove_vertex(v, g);
@@ -281,6 +307,9 @@
     : EdgeMutableGraph<G>
     , VertexMutableGraph<G>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    MutableGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
   };
 
   template <class edge_descriptor>
@@ -293,6 +322,9 @@
   BOOST_concept(MutableIncidenceGraph,(G))
     : MutableGraph<G>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    MutableIncidenceGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~MutableIncidenceGraph() {
       remove_edge(iter, g);
       remove_out_edge_if(u, p, g);
@@ -307,6 +339,9 @@
   BOOST_concept(MutableBidirectionalGraph,(G))
     : MutableIncidenceGraph<G>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+      MutableBidirectionalGraph();   // at least 2.96 and 3.4.3 both need this 
:(
+#endif
       ~MutableBidirectionalGraph()
       {
           remove_in_edge_if(u, p, g);
@@ -320,6 +355,9 @@
   BOOST_concept(MutableEdgeListGraph,(G))
     : EdgeMutableGraph<G>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    MutableEdgeListGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~MutableEdgeListGraph() {
       remove_edge_if(p, g);
     }
@@ -331,6 +369,9 @@
   BOOST_concept(VertexMutablePropertyGraph,(G))
     : VertexMutableGraph<G>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    VertexMutablePropertyGraph();   // at least 2.96 and 3.4.3 both need this 
:(
+#endif
     ~VertexMutablePropertyGraph() {
       v = add_vertex(vp, g);
     }
@@ -343,6 +384,9 @@
     : EdgeMutableGraph<G>
   {
     typedef typename graph_traits<G>::edge_descriptor edge_descriptor;
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    EdgeMutablePropertyGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~EdgeMutablePropertyGraph() {
       p = add_edge(u, v, ep, g);
     }
@@ -356,6 +400,9 @@
     : Graph<G>
   {
     typedef typename graph_traits<G>::edge_descriptor edge_descriptor;
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    AdjacencyMatrix();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~AdjacencyMatrix() {      
       p = edge(u, v, g);
       const_constraints(g);
@@ -373,6 +420,9 @@
   {
     typedef typename property_map<G, Property>::const_type const_Map;
     
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    ReadablePropertyGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~ReadablePropertyGraph()
     {
       BOOST_CONCEPT_ASSERT((ReadablePropertyMapConcept<const_Map, X>));
@@ -393,6 +443,9 @@
     : ReadablePropertyGraph<G, X, Property>
   {
     typedef typename property_map<G, Property>::type Map;
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    PropertyGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~PropertyGraph() {
       BOOST_CONCEPT_ASSERT((ReadWritePropertyMapConcept<Map, X>));
 
@@ -411,6 +464,9 @@
   {
     typedef typename property_map<G, Property>::type Map;
     typedef typename property_map<G, Property>::const_type const_Map;
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    LvaluePropertyGraph();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~LvaluePropertyGraph() {
       BOOST_CONCEPT_ASSERT((LvaluePropertyMapConcept<const_Map, X>));
 
@@ -425,6 +481,9 @@
   // This needs to move out of the graph library
   BOOST_concept(Buffer,(B))
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    Buffer();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~Buffer() {
       b.push(t);
       b.pop();
@@ -448,6 +507,9 @@
     : EqualityComparable<C>
     , DefaultConstructible<C>
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    ColorValue();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~ColorValue() {
       c = color_traits<C>::white();
       c = color_traits<C>::gray();
@@ -458,6 +520,9 @@
 
   BOOST_concept(BasicMatrix,(M)(I)(V))
   {
+#if BOOST_WORKAROUND(__GNUC__, <= 3)
+    BasicMatrix();   // at least 2.96 and 3.4.3 both need this :(
+#endif
     ~BasicMatrix() {
       V& elt = A[i][j];
       const_constraints(A);
@@ -471,6 +536,31 @@
     I i, j;
   };
 
+  } // end namespace concepts
+
+  using boost::concepts::MultiPassInputIteratorConcept;
+  using boost::concepts::GraphConcept;
+  using boost::concepts::IncidenceGraphConcept;
+  using boost::concepts::BidirectionalGraphConcept;
+  using boost::concepts::AdjacencyGraphConcept;
+  using boost::concepts::VertexListGraphConcept;
+  using boost::concepts::EdgeListGraphConcept;
+  using boost::concepts::VertexAndEdgeListGraphConcept;
+  using boost::concepts::EdgeMutableGraphConcept;
+  using boost::concepts::VertexMutableGraphConcept;
+  using boost::concepts::MutableGraphConcept;
+  using boost::concepts::MutableIncidenceGraphConcept;
+  using boost::concepts::MutableBidirectionalGraphConcept;
+  using boost::concepts::MutableEdgeListGraphConcept;
+  using boost::concepts::VertexMutablePropertyGraphConcept;
+  using boost::concepts::EdgeMutablePropertyGraphConcept;
+  using boost::concepts::AdjacencyMatrixConcept;
+  using boost::concepts::ReadablePropertyGraphConcept;
+  using boost::concepts::PropertyGraphConcept;
+  using boost::concepts::LvaluePropertyGraphConcept;
+  using boost::concepts::BufferConcept;
+  using boost::concepts::ColorValueConcept;
+  using boost::concepts::BasicMatrixConcept;
 } // namespace boost
 
 #include <boost/concept/detail/concept_undef.hpp>


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs

Reply via email to