Why would you not use lua for general userland applications?

Why would you not use lua for general userland applications?
Integrantes well with C, luajit is rock solid and fast, llvm-lua is nice.
Luarocks, tables are awesome, easy to learn, and much more.
If more complex things are needed you can also use things like moon script that makes life easier.

Other urls found in this thread:

sites.google.com/site/dorfl68/
twitter.com/AnonBabble

Same reason I dont always bang ur mom when I need to bust a nut.

Its the easiest solution, but not always the best

dayum

Why would you not use golang for general userland applications?
Integrates well with C, go build is rock solid and fast, llgo is nice.
Go rocks, goroutines are awesome, easy to learn, and much more.

Well, it is fast and flexible, it's better than c++ IMHO

Lua is more practical, in overall the performance + ease of use is better.
Go is like C, types in lua makes userland just easier.

I just tried to build a simple ls clone in both, so I could measure their execution time.

Turns out, plain Lua doesn't even have a function to get a directory listing.

For those wondering, the Go implementation takes about the same time as the GNU ls (~0.003s), but is 1.5MB.

Fucking rekt.

Fuck you OP for baiting me into learning yet another language

I must know about 20 languages by now without a single noteworthy project done in any of them

>better than C++ IMHO
Nobody gives a fuck about your "IMHO".
In what objective and quantifiable way is it better than C++?
Got nothing? THEN SHUT YOUR FUCKING MOUTH.

Nobody gives a FUCK about your subjective opinions. If you don't have something of value to others then shut the fuck up. Saying "IMHO" is wasting everyone's time you pussy little shit. If you're going to stand for something then own it like a man instead of hiding behind your bullshit notion that your subjective opinion should be heard-- it shouldn't!

Jesus. Just pick one and do something.

You know, it's really sexy, but I don't see why you don't just use JavaScript instead.

Is there any reason to use vanilla Lua over LuaJIT?

pretty good post IMHO

Dynamic typing is probably the worst idea anybody has ever had.

>integrantes
whoops, spic detected

Why would you not use C++ for general userland applications?
Integrantes well with C, classes are rock solid and fast, GCC and Clang are nice.
C++ rocks, templates are awesome, easy to learn, and much more.
If more complex things are needed you can also use things like Boost that makes life easier.

Why would you not use Lisp for general userland applications?
Integrantes well with C, many compilers which are rock solid and fast.
Macros are awesome, easy to learn, and much more.
If more complex things are needed you can also add more macros that makes life easier.

Because it was designed to be embedded for small scripts, with a nearly non-existing std lib.
Just like JS, but slightly less shitty.

Most statically typed, compiled to binary languages beat LuaJIT and V8 to crap and still manage to have a better std lib.

TL;DR:

>In what objective and quantifiable way is it better than C++?

Source code size & development time of software with equivalent functionality. Lua code is 2-4x more concise than C++.

If you don't value your time you are a codemonkey.

Ha, I wrote ls in node and put it in a dockerised container on the cloud

>In what objective and quantifiable way is it better than C++?
It doesn't try to be "C" plus plus.

I'd take C/LUA over C++ any day.

Tcl is so much better than Lua

> dynamic typing
It's like you want to make slow bug ridden disasters.

LuaJIT is also basically abandoned since Mike Pall stopped working on it and the mainline implementation isn't actually that much faster than every other shitty dynamically typed scripting language.

Nobody is really working on LuaJIT anymore and it already doesn't support some feature of Lua 5.3.

Loose/weak typing is the worst idea anyone ever had. Dynamic typing is second to that.

Cool your autism dude. You don't provide any info on why c++ is better. You're just as bad.

Because Python, that's why.

Aside from what the other dudes mentioned, there aren't really legitimate reasons for JITted embedded scripting languages.

>inb4 JS
That isn't legit.
Only thing I can think of is a scripted shooter bot and even that is borderline, since a bot has to be trusted code and therefore can be a native plugin anyway.

As a rule of thumb, if you need your scripts JIT compiled, your architecure is shitty. Like in a browser or Unity.

Also, JIT compilers can't be used on some devices.

...

sides are gone

>It's like you want to make slow bug ridden disasters.
meme

>and the mainline implementation isn't actually that much faster than every other shitty dynamically typed scripting language.

It is easily 10-20x faster than python or perl. Luajit's performance is second only to V8.

>Aside from what the other dudes mentioned, there aren't really legitimate reasons for JITted embedded scripting languages.

That's why nobody in AAA game industry uses LUAjit... oh wait!

Stop memeing, user.

A very few do this and they do it literally wrong.
And often enough, they pay for it.

Most however use the PUC-RIO implementation.

Stop memeing, user.

...

>It is easily 10-20x faster than python or perl. Luajit's performance is second only to V8.
LuaJIT is not the primary (mainline) implementation and the primary implementation is not 10-20x faster than either Python or Perl for any significant workload. LuaJIT is an alternative implementation which is 10x-20x faster, but it's also not under active development and is basically abandonware since Mike Pall has no interest in working on it anymore.

Most game companies aren't using LuaJIT they're using the primary implementation.

PLEASE help this project: sites.google.com/site/dorfl68/

You're absolutely right, Lua's standard library is pretty sparse. The advantage is that its source tree and memory footprint are booth tiny, which may or may not matter to you depending on the application.

At any rate, an ls clone won't tell you anything about language performance, since the limiting factor there is filesystem performance. Any extra time you'd measure would just be the overhead of starting up the Lua VM and compiling the program to bytecode.

After checking out numerous other scripting languages I found Lua pretty much came out top in terms of both speed, extendability, community, and the API. And that's not even factoring in luajit.

I just wish it didn't index arrays from 1.

>No fuckin switch
>No increment/decrement
>Global everything
Fuck this shit.