lua-users home
lua-l archive

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


On 11.09.2022 20:41, bil til wrote:
  (who really is interestend in seeing all the removed elements? I
think this  would be quite a bizarre wish)

Coincidently, this is exactly my use case and the reason why I had raised this discussion. So yea, the method of the core library should always strive to be generic and unassuming.

I agree that returning something like 10000+ values looks kinda strange, but 3 or 5 or 20 are perfectly reasonable. The thing is, you can never guess how much is gonna be enough for everyone.

If we're going to discard something, we should at least then give the user control over how much elements will be returned and return everything by default.

But that will only further complicate the API, which is, in my opinion, unnecessary at this point as you can safely return half a mil of values.

--
With regards, Alex Ch