perf(lua): do bulk copy of items from heap
perf(lua): do bulk copy of items from heap

Is this better than doing multiple copies? Probably? Hard to know
without having benchmarks up and running yet.

On the plus side, fewer calls to `memcpy()`.  On the cost side,
more pointer indirection. But arguable the sorting is going to be
quicker too (because we're moving pointers around instead of copying
structs). Overall I am guessing it's a win but we'll see later on
perhaps.

wincent/command-t,wincent/command-t,wincent/command-t