News for hackers. Stuff that matters.
Re:Show HN: LadyLua, batteries-included static Lua 5.1 inter... by the_duke on Thursday April 08, 2021 @12:44PM (#26740949)
Go seems like a suboptimal language for implementing an interpreter, since it lacks the low level primitives to make a fast interpreter loop.

But I guess, as will all things Go, that it will be fast enough for a good amount of use cases, and having a language native dependency rather than messing with C libraries is always a plus.

Re:Show HN: LadyLua, batteries-included static Lua 5.1 inter... by Propolice on Thursday April 08, 2021 @12:52PM (#26741047)
Yes, Go is fast enough for some tasks.

Before this I was doing C and PUC-Rio Lua. Was obsessing too much with C pitfalls, valgrind, and the sanitizers. Then LuaJIT FFI + Rust, good I like it better but found GopherLua the easiest. I'd stick with LuaJIT+Rust for anything that needs less resources and speed.

Re:Show HN: LadyLua, batteries-included static Lua 5.1 inter... by pjmlp on Thursday April 08, 2021 @02:28PM (#26742072)
Go has all the required primitives, unsafe and assembler as part of the toolchain.
Re:Show HN: LadyLua, batteries-included static Lua 5.1 inter... by ampdepolymerase on Thursday April 08, 2021 @01:29PM (#26741501)
If he really wanted to, he could have written it as a JIT and generate ASM directly. Writing an executable page is quite trivial in Go.