lua-users home
lua-l archive

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



Eventually, it could be a nice idea for the performance aspects of standard library things (s.a. table.insert) to be listed down systematically. One can, of course, do this by study of the source, but who does? :) I don't.

This could ideally be an appendix of the Lua reference manual (pdf). Just short notes and the O(n) or whatever classification would do..

-ak



15.9.2004 kello 20:30, Mark Hamburg kirjoitti:

 P.S. Actually, table.insert and table.remove are not constant time
operations since they depend on table.getn which depends to some extent on the number of tables with an n field. That, however, is a hash lookup so the
cost grows very slowly.