lua-users home
lua-l archive

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


On Sat, 1 Dec 2018 13:23:34 -0500
Phil Leblanc <philanc@gmail.com> wrote:


> What do you think?

List splitting almost never accomplishes anything good, and often
brings bad things.

I've been gone since 2016 because this list is very prolific and I
didn't have time for it after switching my main language to Python3.

I've come back and noticed something hasn't changed: People keep asking
Lua to become something it isn't. For example, the huge Lua Needs
thread appears to be that somebody needs some sort of scaffolding to do
"composition based OOP" (I don't have the original post).

To me, if there's ever been any language facility supporting
composition, it's the Lua table. And although, at least through Lua
5.3, Lua doesn't have an official, dedicated Object Oriented
Programming syntax. You can accomplish the same things, at least as
easily, using what Lua offers, but it seems like some want Lua to
incorporate riffs from other languages.

I don't.

I've always appreciated the way you can do almost anything with a Lua
table and closures. A developer needn't concern herself with zillions
of complex data types, each having its own methods or performing
differently on shared methods.

I wish people would just let Lua be Lua, and not suggest changes for
the language. If we wanted Rust or Python or C++, we'd be using them.

To me, the only reason to change the language is if the language cannot
perform a task without the change. Years ago, I asked for one change to
Lua: Inclusion of a "continue" statement for loops. When nobody else
found such a construct necessary, I posted a workaround so, within a
loop, I could have a construct that had the role of "give me the next
line and start again at the loop's top." Nobody could find a better way
to perform that role than my workaround, and several people found my
workaround so obscene that a continue statement was added to the
language.

If there's something that Lua can't do in any reasonable way, perhaps a
change in the language is called for. But if a change is proposed to
provide yet another way to do it, why not just use Perl, where "many
ways to do it" is a fundamental part of the language's purpose?

SteveT

Steve Litt 
December 2018 featured book: Rapid Learning for the 21st Century
http://www.troubleshooters.com/rl21