Originally Posted by Resike
Thanks, actually that spairs is awesome. Thats what i need.
|
It's also wasteful if used often: It's creating a new table AND anonymous function every time it's called. I typically just copy the keys from the dictionary-style table to an index-style table and sort on that using a function that I declare/define exactly once. That's essentially what this spairs function is doing, but without creating needless garbage.