lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Sat, Nov 7, 2015 at 10:52 AM, Marco Atzori <> wrote:
Il 07/11/2015 16:46, Matthew Wild ha scritto:
If you have actual constraints, revealing them might allow people to
help you better. If you don't have any constraints and just want it to
perform well, then there are some really much simpler and more
efficient solutions than your implementation.
This code is part of a videogames addon, and is executed every frame refresh (about every tenth of a second) for which using tables created in continuation is a considerable waste of memory. If there are simpler solutions, show them to me as well. I asked your help for this reason ;-)

In trying to avoid table allocation multiple closures and multiple strings are allocated. I'm fairly certain rewriting the code using tables will not only be cleaner but faster with less memory allocation.