# HG changeset patch # User Peter Kovacs # Date 1267224789 -3600 # Node ID aa8c9008b3de9bb247ce81ad736a53c0d96f7b5b # Parent 2914b6f0fde0a1378a2d87c564bd2ac5c9153dda Better return type for cycleLength() functions (#179) in the min mean cycle algorithms. The original Value type is used instead of the LargeValue type, which is introduced for internal computations. diff -r 2914b6f0fde0 -r aa8c9008b3de lemon/hartmann_orlin.h --- a/lemon/hartmann_orlin.h Fri Feb 26 14:00:20 2010 +0100 +++ b/lemon/hartmann_orlin.h Fri Feb 26 23:53:09 2010 +0100 @@ -405,8 +405,8 @@ /// /// \pre \ref run() or \ref findMinMean() must be called before /// using this function. - LargeValue cycleLength() const { - return _best_length; + Value cycleLength() const { + return static_cast(_best_length); } /// \brief Return the number of arcs on the found cycle. diff -r 2914b6f0fde0 -r aa8c9008b3de lemon/howard.h --- a/lemon/howard.h Fri Feb 26 14:00:20 2010 +0100 +++ b/lemon/howard.h Fri Feb 26 23:53:09 2010 +0100 @@ -384,8 +384,8 @@ /// /// \pre \ref run() or \ref findMinMean() must be called before /// using this function. - LargeValue cycleLength() const { - return _best_length; + Value cycleLength() const { + return static_cast(_best_length); } /// \brief Return the number of arcs on the found cycle. diff -r 2914b6f0fde0 -r aa8c9008b3de lemon/karp.h --- a/lemon/karp.h Fri Feb 26 14:00:20 2010 +0100 +++ b/lemon/karp.h Fri Feb 26 23:53:09 2010 +0100 @@ -392,8 +392,8 @@ /// /// \pre \ref run() or \ref findMinMean() must be called before /// using this function. - LargeValue cycleLength() const { - return _cycle_length; + Value cycleLength() const { + return static_cast(_cycle_length); } /// \brief Return the number of arcs on the found cycle.