JakobOvrum/LuaD

Can't assign Lua function to Lua variable

JesseKPhillips opened this issue · 2 comments

When using Lua.get to obtain a function and assign it to a Lua variable the compiler refuses due to the protection level of push in LuaObject (protected).

import luad.all;
import std.stdio;

void main() {
   auto lua = new LuaState;

   lua["print"] = lua.get!LuaFunction("print");
}

This was fixed in one of todays commits.

Thanks, works.