diff -r 7440937d154b -r 157427808b40 lemon/core.h --- a/lemon/core.h Fri Jun 22 16:25:56 2012 +0200 +++ b/lemon/core.h Fri Aug 24 15:37:23 2012 +0200 @@ -1848,15 +1848,26 @@ ///this operator. If you change the outgoing arcs of ///a single node \c n, then \ref refresh(Node) "refresh(n)" is enough. /// -#ifdef DOXYGEN - Arc operator()(Node s, Node t, Arc prev=INVALID) const {} -#else - using ArcLookUp::operator() ; - Arc operator()(Node s, Node t, Arc prev) const + Arc operator()(Node s, Node t, Arc prev=INVALID) const { - return prev==INVALID?(*this)(s,t):_next[prev]; + if(prev==INVALID) + { + Arc f=INVALID; + Arc e; + for(e=_head[s]; + e!=INVALID&&_g.target(e)!=t; + e = t < _g.target(e)?_left[e]:_right[e]) ; + while(e!=INVALID) + if(_g.target(e)==t) + { + f = e; + e = _left[e]; + } + else e = _right[e]; + return f; + } + else return _next[prev]; } -#endif };