An interesting thing about bikesheds is that sometimes they become bikefortresses: if 99% of the world (including the surrounding userbase, in the case of Rust) expects 0-based indexing, then the choice of something that uses 1-based indexing is harder to justify.
This doesn't make one better than the other, but precedent/familiarity does matter and represents a valid decision weight.
I don't particularly disagree. Although it's worth noting that people don't typically pick embedded languages because they're familiar with the embedded language per se, but instead because they (1) are easy to integrate, and (2) resemble the syntax/semantics of the embedding language. Rhai appears to satisfy both, so I can understand why someone would pick it.
(I don't have a dog in this fight; I'm not a user of either Lua or Rhai.)
No one can convince me thst 0-based indexing is worth more than widespread editor syntax -highlighting support, working LSPs, lots of blog posts, books and more vs a new niche language whose marquee feature seems to be it is easier to embed in rust.
Again, I don't want to put down the authors, making languages and tooling is fun and awesome, but I wouldn't pretend this is a rstional replacement for Lua.
It's absolutely a valid and serious answer? You asked for reasons, omitting two options, and they gave you a list of points for and against not including those two options. That's a good response, you don't need to agree with it, but I don't see how you can call it not serious?
The answer as a whole is serious, I said as much, read again.
A singled out this one point, because it is not.
It is akin to any other knee-jerk dismissive attitude to anything different.
Casting away a far more proven language, used for over a decade in thousands of serious, commercial projects with wide editor (and LSP) support etc over indexing conventions, is not serious.
Lua is my first 1-indexed language, i have yet to have a single bug over this. It's a irrational fear.
But a vague, unsubstantiated feeling that one day, you might introduce a one-off indexing bug should not justify discarding Lua, and all its substantial benefits over project.
Arguing the pro's of Rust data-structure interop in case of a Rust project - that makes sense. This, this is basically nonsense.
> But a vague, unsubstantiated feeling that one day, you might introduce a one-off indexing bug should not justify discarding Lua, and all its substantial benefits over project.
Nobody said anything like that. There's no vague feeling of indexing bugs; there's a concrete degradation of code quality.
And yes it's only one factor, not a deal-breaker. Nobody here said it was.
I never said 0-based indexing was sufficient to choose it over Lua on its own. Just that it is an advantage over Lua, which it is.
Also I don't think Lua's LSP/type annotations are anything to boast about. They exist, but they aren't good. If you care about that there are way better choices - Typescript, or maybe Dart (not sure how embeddable that is though).
I don't mean to be overly harsh, but this is just not a valid/serious answer. The other reasons are fine. This is pure bike-shedding.