fix: CodeQL warnings in `machine_learning/a_st...

...`ar_search.cpp`
This commit is contained in:
David Leal 2021-04-08 18:39:28 -05:00
parent 0a596dd7aa
commit 8adaec948c
No known key found for this signature in database
GPG Key ID: 3C482B03FD220E68

View File

@ -305,7 +305,7 @@ class AyStarSearch {
* @brief constructor having Puzzle as parameter
* @param A a puzzle object
*/
explicit Info(Puzzle A) : state(std::move(A)) {}
explicit Info(const Puzzle &A) : state(std::move(A)) {}
/**
* @brief constructor having three parameters
@ -313,7 +313,7 @@ class AyStarSearch {
* @param h_value heuristic value of this puzzle object
* @param depth the depth at which this node was found during traversal
*/
Info(Puzzle A, size_t h_value, size_t d)
Info(const Puzzle &A, size_t h_value, size_t d)
: state(std::move(A)), heuristic_value(h_value), depth(d) {}
/**