rua 0.1.3-mswin32 → 0.1.4-mswin32
Sign up to get free protection for your applications and to get access to all the features.
- data/README.txt +21 -0
- data/lib/i386-mswin32/rua.so +0 -0
- metadata +2 -2
data/README.txt
CHANGED
@@ -45,3 +45,24 @@ Rua is a library for using Lua under Ruby.
|
|
45
45
|
|
46
46
|
rua.f.call
|
47
47
|
p rua.eval('return 1, 2, 3')
|
48
|
+
|
49
|
+
co = rua.eval(<<-EOS)
|
50
|
+
function foo (a)
|
51
|
+
print('foo', a)
|
52
|
+
return coroutine.yield(2 * a)
|
53
|
+
end
|
54
|
+
|
55
|
+
return coroutine.create(function (a, b)
|
56
|
+
print('co-body', a, b)
|
57
|
+
local r = foo(a + 1)
|
58
|
+
print('co-body', r)
|
59
|
+
local r, s = coroutine.yield(a + b, a - b)
|
60
|
+
print('co-body', r, s)
|
61
|
+
return b, 'end'
|
62
|
+
end)
|
63
|
+
EOS
|
64
|
+
|
65
|
+
p co.resume(1, 10)
|
66
|
+
p co.resume('r')
|
67
|
+
p co.resume('x', 'y')
|
68
|
+
p co.resume('x', 'y')
|
data/lib/i386-mswin32/rua.so
CHANGED
Binary file
|
metadata
CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.2
|
|
3
3
|
specification_version: 1
|
4
4
|
name: rua
|
5
5
|
version: !ruby/object:Gem::Version
|
6
|
-
version: 0.1.
|
7
|
-
date: 2007-11-
|
6
|
+
version: 0.1.4
|
7
|
+
date: 2007-11-15 00:00:00 +09:00
|
8
8
|
summary: rua is a library for using Lua under Ruby.
|
9
9
|
require_paths:
|
10
10
|
- lib/i386-mswin32
|