From 387ceaf14743d472311d66ee64ba960845163f6f Mon Sep 17 00:00:00 2001 From: Ashish Bhanu Daulatabad Date: Tue, 23 Mar 2021 22:12:29 +0530 Subject: [PATCH] Code refactoring-5. --- machine_learning/a_star_search.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/machine_learning/a_star_search.cpp b/machine_learning/a_star_search.cpp index 87d0d2577..416e3e506 100644 --- a/machine_learning/a_star_search.cpp +++ b/machine_learning/a_star_search.cpp @@ -156,7 +156,7 @@ class EightPuzzle { * @details Move assignment operator * @param A a reference of an EightPuzzle */ - EightPuzzle operator=(const EightPuzzle &&A) noexcept { + EightPuzzle &operator=(EightPuzzle &&A) noexcept { board = std::move(A.board); return *this; } @@ -328,7 +328,7 @@ class AyStarSearch { /** * @details move assignment operator */ - Info &operator=(const Info &&A) noexcept { + Info &operator=(Info &&A) noexcept { state = std::move(A.state); heuristic_value = std::move(A.heuristic_value); depth = std::move(A.depth);