← Back to team overview

widelands-dev team mailing list archive

Re: [Merge] lp:~widelands-dev/widelands/bug-1574379-forester-wit into lp:widelands

 

> return forester_cache[mi] = correct_val;
< forester_cache[mi] = correct_val;"
< return correct_val;

Well any compiler with some omptimization should optimize this away.
Maybe som bad habit from the old days of C programming :-)


> The comparison (cache_entry > kInvalidForesterEntry) looks weird. 

Yes I thought about this, too. It its more robust, in case one of the
calculactions later returns some negative value this might fix it?

Feel freee to change these aspects as you wish.
-- 
https://code.launchpad.net/~widelands-dev/widelands/bug-1574379-forester-wit/+merge/336068
Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/bug-1574379-forester-wit.


References