[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: New array type? (was: 'table' as fallback for tables)
- From: Peter Melnichenko <mpeterval@...>
- Date: Fri, 1 Jul 2016 12:03:40 +0300
On Fri, Jul 1, 2016 at 7:09 AM, Philipp Janda <siffiejoe@gmx.net> wrote:
> There are few smaller steps we can make:
>
> * Solve the `pack()`/`unpack()` symmetry problem.
> * Enhance the table library to allow non-sequence based array
> implementations by adding a library metamethod `__resize` or `__setsize`, so
> that `table.insert()` and `table.remove()` can adjust the array sizes
> accordingly (`table.move()` is more complicated).
Does the second point mean I'll have to check for the new metamethod and
call it whenever I modify array part of a table passed to me from outside?
-- Peter