4 ms·
What's wrong with the comment syntax? > Also, seriously? Double is more than enough for integers? Not saying that I like it, but it's the same as Javascript.
by jolmg 6y ago
What's wrong with the comment syntax?
> Also, seriously? Double is more than enough for integers?
Not saying that I like it, but it's the same as Javascript. If I recall right, Lua is heavily influenced by JS.
- VWWHFSfQ 6y agoLua predates JavaScript by several years. Maybe you meant that JavaScript was influenced by Lua?
- jolmg 6y agoHuh. You're right. Though not several years apart, Lua appeared in 1993 and JS in 1995. I wonder if there's a similar HOPL paper for JS that could confirm Lua's influence.
- SanderSantema 6y agoI don’t think it’s influenced by js: http://www.lua.org/doc/hopl.pdf http://www.lua.org/doc/hopl.pdf
- jolmg 6y agoMust have been just the impression I got. When I read about it many years ago, I thought it was very much like JS except with a different syntax. I mean, besides the number thing, it uses prototypes for inheritance, and its "tables" are very much like JS objects in the way of how o.x == o["x"] for example, or how arrays are basically built on them (though augmented with a little syntax-sugar). I don't know of other languages that share these characteristics.
- colonwqbang 6y agoLua is older than Javascript so if anything it is Javascript which took inspiration from Lua.
- alwillis 6y agoSeems that Lua and NewtonScript share at least the prototypical inheritance: https://en.wikipedia.org/wiki/NewtonScript https://en.wikipedia.org/wiki/NewtonScript
- greenshackle2 6y agoThat would be rather surprising, since Lua predates Javascript.
- tzot 6y agoUnless time machines are involved, I would rather say that Lua is heavily influenced by awk :)
- runxel 6y ago> What's wrong with the comment syntax? Not OP, but for me it's not... "blocky" enough? Especially for inline commands it's maybe just too easy to glimpse over it. But otherwise it's also maybe just plain unfamiliar.