Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Embedded scripting languages

Name: Anonymous 2014-11-06 8:40

What scripting language would you embed to a program? The performance would not be main issue, since the compiled part of the program would worry about that.

The scripting language would call many functions written in C, C++, or whatever lang that can compile C-like functions (so there needs to be some kind of easy to use FFI).

I thought about options here:
- Lua
- Scheme (tinyscheme or whatever)
- Something else?

Now, what would /prog/ use, and why? ("Read SICP" is not a valid answer here)

Name: Anonymous 2014-11-07 21:20

>>26
I've defended Lua on /prog/ for years now. It's not my favorite language but it's a lot better than you guys are making it out to be; in particular, the complaints about performance are downright retarded when LuaJIT wipes the floor with just about every other dynamic language, and provides comparable throughput to average C and C++ (naïve, safe stuff with lots of heap allocations, not VROOM VROOM OPTIMIZED stuff with custom memory allocators and whatnot) when you use LuaJIT's FFI types.

If you want to ship an application with an embedded scripting language on Windows, Linux, and OSX, LuaJIT is the best choice, hands down. Everything else has some combination of these problems:
-performance isn't as good
-footprint is too large (fuck you, I'm not gonna ship a 100+ megabyte Common Lisp runtime)
-inadequate Windows support (I don't give a fuck about your FSF dogma, I write programs for normal people and normal people use Windows)
-is a toy some kid made for a CS project that doesn't have a large userbase working out the bugs and funding development
-is stuck in web server/command line scripting la-la-land with zero concern for putting bounds on latency (LuaJIT isn't perfect at this either but the incremental GC gives you a lot more control than most languages dynamic languages)
-shit FFI requiring you to waste time with wrappers

I'd rather be using a Lisp, but none of them are even close to being as good as LuaJIT in these aspects.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List