1.1 --- a/lemon/bfs.h Wed Nov 16 05:01:04 2005 +0000
1.2 +++ b/lemon/bfs.h Wed Nov 16 09:08:36 2005 +0000
1.3 @@ -228,7 +228,7 @@
1.4 template <class T>
1.5 struct DefPredMapTraits : public Traits {
1.6 typedef T PredMap;
1.7 - static PredMap *createPredMap(const Graph &G)
1.8 + static PredMap *createPredMap(const Graph &)
1.9 {
1.10 throw UninitializedParameter();
1.11 }
1.12 @@ -245,7 +245,7 @@
1.13 template <class T>
1.14 struct DefDistMapTraits : public Traits {
1.15 typedef T DistMap;
1.16 - static DistMap *createDistMap(const Graph &G)
1.17 + static DistMap *createDistMap(const Graph &)
1.18 {
1.19 throw UninitializedParameter();
1.20 }
1.21 @@ -262,7 +262,7 @@
1.22 template <class T>
1.23 struct DefReachedMapTraits : public Traits {
1.24 typedef T ReachedMap;
1.25 - static ReachedMap *createReachedMap(const Graph &G)
1.26 + static ReachedMap *createReachedMap(const Graph &)
1.27 {
1.28 throw UninitializedParameter();
1.29 }
2.1 --- a/lemon/dfs.h Wed Nov 16 05:01:04 2005 +0000
2.2 +++ b/lemon/dfs.h Wed Nov 16 09:08:36 2005 +0000
2.3 @@ -1049,6 +1049,7 @@
2.4 return DfsWizard<DfsWizardBase<GR> >(g,s);
2.5 }
2.6
2.7 +#ifdef DOXYGEN
2.8 /// \brief Visitor class for dfs.
2.9 ///
2.10 /// It gives a simple interface for a functional interface for dfs
2.11 @@ -1084,10 +1085,25 @@
2.12 /// \brief Called for the source node of the dfs.
2.13 ///
2.14 /// It is called for the source node of the dfs.
2.15 - void start(const Node&) {}
2.16 + void start(const Node& node) {}
2.17 /// \brief Called when we leave the source node of the dfs.
2.18 ///
2.19 /// It is called when we leave the source node of the dfs.
2.20 + void stop(const Node& node) {}
2.21 +
2.22 + };
2.23 +#else
2.24 + template <typename _Graph>
2.25 + struct DfsVisitor {
2.26 + typedef _Graph Graph;
2.27 + typedef typename Graph::Edge Edge;
2.28 + typedef typename Graph::Node Node;
2.29 + void discover(const Edge&) {}
2.30 + void reach(const Node&) {}
2.31 + void backtrack(const Edge&) {}
2.32 + void leave(const Node&) {}
2.33 + void examine(const Edge&) {}
2.34 + void start(const Node&) {}
2.35 void stop(const Node&) {}
2.36
2.37 template <typename _Visitor>
2.38 @@ -1106,6 +1122,7 @@
2.39 _Visitor& visitor;
2.40 };
2.41 };
2.42 +#endif
2.43
2.44 /// \brief Default traits class of DfsVisit class.
2.45 ///