rua 0.1.1-mswin32 → 0.1.2-mswin32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. data/README.txt +12 -4
  2. data/lib/i386-mswin32/rua.so +0 -0
  3. metadata +1 -1
data/README.txt CHANGED
@@ -10,7 +10,11 @@ Rua is a library for using Lua under Ruby.
10
10
 
11
11
  require 'rua'
12
12
 
13
- rua = Rua.new
13
+ error_handler = lambda do |e|
14
+ p e
15
+ end
16
+
17
+ rua = Rua.new(error_handler)
14
18
  rua.openlibs(:all)
15
19
  #rua.openlibs(:base, :package, :string)
16
20
  #rua.secure = false
@@ -18,15 +22,19 @@ Rua is a library for using Lua under Ruby.
18
22
  rua[:str] = 'xxx'
19
23
  rua[:num] = 100
20
24
  rua[:proc] = lambda do
21
- puts 'Proc called.'
25
+ puts 'proc called.'
26
+ end
27
+ rua[:err] = lambda do
28
+ raise 'err called.'
22
29
  end
23
30
 
24
- puts rua.eval(<<EOS)
31
+ puts rua.eval(<<-EOS)
25
32
  print('hello Rua!')
26
33
  print(str)
27
34
  print(num)
28
35
  proc()
29
-
36
+ err()
37
+
30
38
  f = function()
31
39
  print('f() called.')
32
40
  end
Binary file
metadata CHANGED
@@ -3,7 +3,7 @@ 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.1
6
+ version: 0.1.2
7
7
  date: 2007-11-14 00:00:00 +09:00
8
8
  summary: rua is a library for using Lua under Ruby.
9
9
  require_paths: