diff -r dbe3fc9c875d -r 32155c88f59b lemon/list_graph.h --- a/lemon/list_graph.h Tue Jul 29 14:41:55 2008 +0200 +++ b/lemon/list_graph.h Tue Jul 29 15:06:37 2008 +0200 @@ -842,7 +842,9 @@ explicit Arc(int pid) { id = pid;} public: - operator Edge() const { return edgeFromId(id / 2); } + operator Edge() const { + return id != -1 ? edgeFromId(id / 2) : INVALID; + } Arc() {} Arc (Invalid) { id = -1; }