Pass parameter by const ref instead of const value.
Issue found by cppcheck.
This commit is contained in:
parent
fbdd326260
commit
033d07ea66
1 changed files with 2 additions and 2 deletions
|
@ -43,8 +43,8 @@ namespace game_logic {
|
|||
typedef std::pair< unit_map::unit_iterator, int> unit_formula_pair;
|
||||
|
||||
struct unit_formula_compare {
|
||||
bool operator() (const unit_formula_pair left,
|
||||
const unit_formula_pair right) const
|
||||
bool operator() (const unit_formula_pair& left,
|
||||
const unit_formula_pair& right) const
|
||||
{
|
||||
return left.second > right.second;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue