---
milena/mln/util/internal/graph_vertex_iter.hh | 12 +++++++++++-
1 files changed, 11 insertions(+), 1 deletions(-)
diff --git a/milena/mln/util/internal/graph_vertex_iter.hh
b/milena/mln/util/internal/graph_vertex_iter.hh
index 9d2f3df..da564e7 100644
--- a/milena/mln/util/internal/graph_vertex_iter.hh
+++ b/milena/mln/util/internal/graph_vertex_iter.hh
@@ -71,6 +71,8 @@ namespace mln
unsigned index() const;
/// \}
+ void update_graph(const G& g);
+
/// Proxy.
/// \{
/// Proxy subject
@@ -136,8 +138,8 @@ namespace mln
template<typename G>
inline
vertex_fwd_iterator<G>::vertex_fwd_iterator(const G& g)
- : v_(util::vertex<G>(&g))
{
+ update_graph(g);
invalidate();
}
@@ -175,6 +177,14 @@ namespace mln
template<typename G>
inline
+ void
+ vertex_fwd_iterator<G>::update_graph(const G& g)
+ {
+ v_ = util::vertex<G>(&g);
+ }
+
+ template<typename G>
+ inline
unsigned
vertex_fwd_iterator<G>::index() const
{
--
1.5.6.5