From 77f5ba71740fc9cecca7d01617f1b7a3399985ae Mon Sep 17 00:00:00 2001 From: boufaras Date: Wed, 6 Jul 2011 13:09:34 +0000 Subject: [PATCH] redundant code ( moveBack is simple call of move on same solution) git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@2289 331e1502-861f-0410-8da2-ba01fb791d7f --- .../src/problems/permutation/moIndexedSwapNeighbor.h | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/trunk/paradiseo-mo/src/problems/permutation/moIndexedSwapNeighbor.h b/trunk/paradiseo-mo/src/problems/permutation/moIndexedSwapNeighbor.h index 998699ab0..0b503ca35 100644 --- a/trunk/paradiseo-mo/src/problems/permutation/moIndexedSwapNeighbor.h +++ b/trunk/paradiseo-mo/src/problems/permutation/moIndexedSwapNeighbor.h @@ -74,15 +74,8 @@ public: * @param _solution the solution to move back */ virtual void moveBack(EOT& _solution) { - unsigned int tmp; - unsigned i, j; - this->getIndices(_solution.size(), i, j); - tmp = _solution[i]; - _solution[i] = _solution[j]; - _solution[j] = tmp; - - _solution.invalidate(); + move(_solution); } /**