Pass parameter by const ref instead of const value.

Issue found by cppcheck.
This commit is contained in:
Mark de Wever 2009-10-17 05:37:53 +00:00
parent ff27cb8f63
commit b73d1ac9b8
2 changed files with 2 additions and 2 deletions

View File

@ -853,7 +853,7 @@ double testing_move_to_targets_phase::rate_group(const std::set<map_location>& g
bool testing_move_to_targets_phase::should_retreat(const map_location& loc, const unit_map::const_iterator un,
bool testing_move_to_targets_phase::should_retreat(const map_location& loc, const unit_map::const_iterator& un,
const move_map& srcdst, const move_map& dstsrc, const move_map& enemy_dstsrc,
double caution)
{

View File

@ -74,7 +74,7 @@ protected:
const move_map& dstsrc, const move_map& enemy_dstsrc,
const plain_route& rt);
bool should_retreat(const map_location& loc, const unit_map::const_iterator un,
bool should_retreat(const map_location& loc, const unit_map::const_iterator& un,
const move_map& srcdst, const move_map& dstsrc, const move_map& enemy_dstsrc,
double caution);
};