digitalmars.D - Best Lua integration?
- Kim (8/8) Nov 16 2016 Hello
- Mike Parker (6/14) Nov 16 2016 I can't speak for LuaD, but DerelictLua should be perfectly
- rikki cattermole (4/12) Nov 16 2016 LuaD is a lot more then just a binding. It does have static bindings to
- Soulsbane (3/20) Nov 16 2016 Not to mention much more high level(LuaD).
- Kim (7/28) Nov 16 2016 Yes I see the higher level as a weakness. It may save you time to
- Mike Parker (7/11) Nov 16 2016 Some of the Derelict bindings already support a static
- Chris (7/14) Nov 17 2016 I've worked with both. I prefer DerelictLua, because you have
- Jesse Phillips (9/16) Nov 17 2016 For your desires Derelict sounds like the best option. I
Hello what is the best Lua integration available? I have found these two so far: * https://github.com/JakobOvrum/LuaD (only Lua 5.1) * https://github.com/DerelictOrg/DerelictLua (Lua 5.3) The former seems better/more active. Are there other similar projects that I am missing? Thanks
Nov 16 2016
On Wednesday, 16 November 2016 at 22:53:46 UTC, Kim wrote:Hello what is the best Lua integration available? I have found these two so far: * https://github.com/JakobOvrum/LuaD (only Lua 5.1) * https://github.com/DerelictOrg/DerelictLua (Lua 5.3) The former seems better/more active. Are there other similar projects that I am missing? ThanksI can't speak for LuaD, but DerelictLua should be perfectly usable. Don't let the lack of activity scare you. It's a binding, the sort of thing that's implemented once and forgotten about except for bug fixes and updates. I updated it earlier this year for Lua 5.3. If people report issues, I'll fix them.
Nov 16 2016
On 17/11/2016 11:53 AM, Kim wrote:Hello what is the best Lua integration available? I have found these two so far: * https://github.com/JakobOvrum/LuaD (only Lua 5.1) * https://github.com/DerelictOrg/DerelictLua (Lua 5.3) The former seems better/more active. Are there other similar projects that I am missing? ThanksLuaD is a lot more then just a binding. It does have static bindings to Lua. Where as DerelictLua has dynamic bindings (linking is done at runtime to shared libraries).
Nov 16 2016
On Thursday, 17 November 2016 at 03:46:26 UTC, rikki cattermole wrote:On 17/11/2016 11:53 AM, Kim wrote:Not to mention much more high level(LuaD).Hello what is the best Lua integration available? I have found these two so far: * https://github.com/JakobOvrum/LuaD (only Lua 5.1) * https://github.com/DerelictOrg/DerelictLua (Lua 5.3) The former seems better/more active. Are there other similar projects that I am missing? ThanksLuaD is a lot more then just a binding. It does have static bindings to Lua. Where as DerelictLua has dynamic bindings (linking is done at runtime to shared libraries).
Nov 16 2016
On Thursday, 17 November 2016 at 04:54:02 UTC, Soulsbane wrote:On Thursday, 17 November 2016 at 03:46:26 UTC, rikki cattermole wrote:Yes I see the higher level as a weakness. It may save you time to integrate in D, but tries to hide complexity. Hiding complexity can hurt in other ways. I think I will go for the more C-like binding of DerelictLua; I am fine for the shared libraries binding as I don't need static bindings, but I guess that could be added without too much effort?On 17/11/2016 11:53 AM, Kim wrote:Not to mention much more high level(LuaD).Hello what is the best Lua integration available? I have found these two so far: * https://github.com/JakobOvrum/LuaD (only Lua 5.1) * https://github.com/DerelictOrg/DerelictLua (Lua 5.3) The former seems better/more active. Are there other similar projects that I am missing? ThanksLuaD is a lot more then just a binding. It does have static bindings to Lua. Where as DerelictLua has dynamic bindings (linking is done at runtime to shared libraries).
Nov 16 2016
On Thursday, 17 November 2016 at 06:33:06 UTC, Kim wrote:I think I will go for the more C-like binding of DerelictLua; I am fine for the shared libraries binding as I don't need static bindings, but I guess that could be added without too much effort?Some of the Derelict bindings already support a static configuration. I intend to add one to DerelictLua in the very near future. I've got a little tool that can convert Derelict-style function pointer declarations into standard function declarations for a static binding, so yeah, it's easy to do.
Nov 16 2016
On Thursday, 17 November 2016 at 06:33:06 UTC, Kim wrote:Yes I see the higher level as a weakness. It may save you time to integrate in D, but tries to hide complexity. Hiding complexity can hurt in other ways. I think I will go for the more C-like binding of DerelictLua; I am fine for the shared libraries binding as I don't need static bindings, but I guess that could be added without too much effort?I've worked with both. I prefer DerelictLua, because you have more direct control. But be prepared to deal with Lua stacks and its C API, which can be a bit annoying at times. You'll probably start writing you own D wrappers for convenience (that's where D's templates shine) and end up with something like LuaD - which makes you appreciate LuaD even more.
Nov 17 2016
On Thursday, 17 November 2016 at 06:33:06 UTC, Kim wrote:Yes I see the higher level as a weakness. It may save you time to integrate in D, but tries to hide complexity. Hiding complexity can hurt in other ways. I think I will go for the more C-like binding of DerelictLua; I am fine for the shared libraries binding as I don't need static bindings, but I guess that could be added without too much effort?For your desires Derelict sounds like the best option. I definitely recommend LuaD though. I'm not sure what complexity your concerned about hiding, you're trying to interface with a dynamic language, LuaD provides "high level" functions which handle adding and removing D/Lua objects from the Lua stack and interacting with Lua objects directly. You should still be able to manipulate Lua through the C API, I just don't know why you'd want to put yourself through that.
Nov 17 2016