Closed XmiliaH closed 2 months ago
Part of me wonders if we should even continue to support the if-expression. I have no data as for the prevalence of it, especially considering Lua forks other than Pluto, but I can't imagine it's worthwhile in the slightest when most people either don't use it or use the compact ternary expression. @well-in-that-case Thoughts?
Part of me wonders if we should even continue to support the if-expression. I have no data as for the prevalence of it, especially considering Lua forks other than Pluto, but I can't imagine it's worthwhile in the slightest when most people either don't use it or use the compact ternary expression. @well-in-that-case Thoughts?
The documented purpose of the alternative ternary syntax is legacy compatibility with older Pluto versions. Much time has passed since then, so considering deprecation would not be unreasonable. However, I don't view this syntax as a burden either.
For cases like this, it kind of is a burden, but for the $if
statement, we can specialize for the '$'. That at least resolves this bug on 0.10.0.
The
skip_block
function used for the const if statement cannot handle the if expression since it expects it to end withend
which it does not.