← Back to team overview

widelands-dev team mailing list archive

Re: [Merge] lp:~widelands-dev/widelands/bug-1772168-unused-key-in-luatable into lp:widelands


Review: Approve code

Code LGTM. Nice catch :)
The problem was that the WorkerDescr fetched the table, then took only value [1], then discarded the table, so [2] was unused. Then it fetched the table anew, used only key [2], and discarded the table, so value [1] was unused. A table always prints warnings about unused keys when being deleted. get_vector() is a very elegant workaround for this :)
Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/bug-1772168-unused-key-in-luatable.