Initial draft of interpreter. Lua compiled "chunks" can be unmarshalled. Approximately half of bytecodes implemented in some form or another.
This commit is contained in:
10
src/test/res/test2.lua
Normal file
10
src/test/res/test2.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
function sum(a,b,c,d) -- "sum" method
|
||||
return a+b+c+d -- return sum
|
||||
end
|
||||
print( sum( 1, 2, 3, 4 ) )
|
||||
print( sum( 5, 6, 7 ) )
|
||||
print( sum( 9, 10, 11, 12, 13, 14 ) )
|
||||
print( sum( sum(1,2,3,4), sum(5,6,7), sum(9,10,11,12,13,14), 15 ) )
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user