simplify LuaCompiler interface and add Lua2Java utility class.

This commit is contained in:
James Roseborough
2010-07-25 22:31:43 +00:00
parent 97b4162423
commit 69bbae70a1
14 changed files with 238 additions and 110 deletions

View File

@@ -56,9 +56,7 @@ public class TestLuaJ {
// compile into a chunk, or load as a class
InputStream is = new ByteArrayInputStream( script.getBytes() );
Prototype p = LuaC.compile(is, "script");
print( p );
LuaValue chunk = new LuaClosure(p,_G);
LuaValue chunk = LuaC.instance.load(is, "script",_G);
chunk.call();
}