Lua supports function calls without parentheses for specific kinds of literals:
-- equivalent to my_func("str")
local a = my_func "str"
-- equivalent to other_func({1, 2})
local b = other_func {1, 2}
Clue could support no-parentheses string calls just fine, and could probably make it work with special strings too (like raw). Although, the table param call will be problematic since code blocks also use { }.
On the other hand, method calls (class::method()) could support single table params as the call can't be confused with a expression + block combination. Slightly useful for class-related structures:
calls without () for strings would be fine, but {} could easily get ambiguous so I'm not sure if it's even possible
even if methods wouldn't have this issue, I'd rather not have it work with just methods
Lua supports function calls without parentheses for specific kinds of literals:
Clue could support no-parentheses string calls just fine, and could probably make it work with special strings too (like raw). Although, the table param call will be problematic since code blocks also use
{ }
.On the other hand, method calls (
class::method()
) could support single table params as the call can't be confused with a expression + block combination. Slightly useful for class-related structures: