>If we have a check as part of the stylechecker for this, then I think someone
>should check whether that still works and is run.
I was mistaken here. We have a check which checks for the inverse
(!blah.size()) which should then
be replaced through blah.empty().
>How can logic/building.cc:686 ever be called when the if has the same check as
>the while loop above?
There is a break statement in the while loop which will terminate the
loop. So this is valid.
>The cppcheck report also listed logic/tribe.cc:233, but that section looks a
>bit special and I'm not sure what's going on there, so I left it alone...
It is save to replace this too:
if (!column.empty())
but it will not make a notable difference in performance. It will only
shut up cppcheck.
--
https://code.launchpad.net/~hjd/widelands/optimizations/+merge/101116
Your team Widelands Developers is requested to review the proposed merge of
lp:~hjd/widelands/optimizations into lp:widelands.
_______________________________________________
Mailing list: https://launchpad.net/~widelands-dev
Post to : [email protected]
Unsubscribe : https://launchpad.net/~widelands-dev
More help : https://help.launchpad.net/ListHelp