Lua::StackMixin::Chunk
Instance methods
Evaluates a Lua chunk and returns the result if any.
You can set the name of your chunk using name var.
Stack.new.run %q{
double = function (x)
return x * 2
end
return double(double(2))
} # => 8
Evaluates a Lua chunk and returns the result if any.
You can set the name of your chunk using name var.
Stack.new.run %q{
double = function (x)
return x * 2
end
return double(double(2))
} # => 8