News for hackers. Stuff that matters.
Re:What's New in Lua 5.4 by a1369209993 on Wednesday July 15, 2020 @09:44PM (#23854818)

  > for (int i = n - 1; i >= 0; i--) { // half open
Well, there's your problem right there[0]; it should be:

  for(size_t i = n; i-- > 0 ;) {
> This is all said without even going into the awkwardness of having [k] being the {k+1}th element

You mean the awkwardness of humans using "kth" to refer to element number k-1?

0: /sarcasm

Re:What's New in Lua 5.4 by mingodad on Thursday July 16, 2020 @02:52AM (#23856504)
Your example doesn't hold water, size_t is unsigned so the test condition would never be met.
Re:What's New in Lua 5.4 by anonymoushn on Thursday July 16, 2020 @03:28AM (#23856685)