Author: fperrad
Date: Fri Aug  8 23:36:03 2008
New Revision: 30137

Modified:
   branches/opengl4lua/languages/lua/src/lib/base64.pir
   branches/opengl4lua/languages/lua/src/lib/bc.pir
   branches/opengl4lua/languages/lua/src/lib/bitlib.pir
   branches/opengl4lua/languages/lua/src/lib/glut.pir
   branches/opengl4lua/languages/lua/src/lib/lfs.pir
   branches/opengl4lua/languages/lua/src/lib/luaaux.pir
   branches/opengl4lua/languages/lua/src/lib/luabasic.pir
   branches/opengl4lua/languages/lua/src/lib/luacoroutine.pir
   branches/opengl4lua/languages/lua/src/lib/luadebug.pir
   branches/opengl4lua/languages/lua/src/lib/luafile.pir
   branches/opengl4lua/languages/lua/src/lib/luaio.pir
   branches/opengl4lua/languages/lua/src/lib/luamath.pir
   branches/opengl4lua/languages/lua/src/lib/luaos.pir
   branches/opengl4lua/languages/lua/src/lib/luapackage.pir
   branches/opengl4lua/languages/lua/src/lib/luastring.pir
   branches/opengl4lua/languages/lua/src/lib/luatable.pir
   branches/opengl4lua/languages/lua/src/lib/md5.pir
   branches/opengl4lua/languages/lua/src/lib/random.pir
   branches/opengl4lua/languages/lua/src/lib/uuid.pir
   branches/opengl4lua/languages/lua/src/yapp/Lua/build.pm
   branches/opengl4lua/languages/lua/t/   (props changed)

Log:
[Lua] merge from trunk (30102 -> 30136)

Modified: branches/opengl4lua/languages/lua/src/lib/base64.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/base64.pir        (original)
+++ branches/opengl4lua/languages/lua/src/lib/base64.pir        Fri Aug  8 
23:36:03 2008
@@ -43,7 +43,10 @@
     set $P1, MYNAME
     _lua__GLOBAL[$P1] = _base64
 
-    $P2 = split ' ', 'decode encode'
+    $P2 = split "\n", <<'LIST'
+decode
+encode
+LIST
     lua_register($P1, _base64, $P2)
 
     new $P2, 'LuaString'

Modified: branches/opengl4lua/languages/lua/src/lib/bc.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/bc.pir    (original)
+++ branches/opengl4lua/languages/lua/src/lib/bc.pir    Fri Aug  8 23:36:03 2008
@@ -51,7 +51,24 @@
     set $P1, MYNAME
     _lua__GLOBAL[$P1] = _bc
 
-    $P2 = split ' ', 'digits tostring iszero isneg number compare __eq __lt 
add sub mul pow div mod sqrt __unm'
+    $P2 = split "\n", <<'LIST'
+digits
+tostring
+iszero
+isneg
+number
+compare
+__eq
+__lt
+add
+sub
+mul
+pow
+div
+mod
+sqrt
+__unm
+LIST
     lua_register($P1, _bc, $P2)
 
     set $P1, 'add'

Modified: branches/opengl4lua/languages/lua/src/lib/bitlib.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/bitlib.pir        (original)
+++ branches/opengl4lua/languages/lua/src/lib/bitlib.pir        Fri Aug  8 
23:36:03 2008
@@ -45,7 +45,16 @@
     set $P1, MYNAME
     _lua__GLOBAL[$P1] = _bitlib
 
-    $P2 = split ' ', 'cast bnot band bor bxor lshift rshift arshift'
+    $P2 = split "\n", <<'LIST'
+cast
+bnot
+band
+bor
+bxor
+lshift
+rshift
+arshift
+LIST
     lua_register($P1, _bitlib, $P2)
 
     new $P2, 'LuaNumber'

Modified: branches/opengl4lua/languages/lua/src/lib/glut.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/glut.pir  (original)
+++ branches/opengl4lua/languages/lua/src/lib/glut.pir  Fri Aug  8 23:36:03 2008
@@ -46,7 +46,20 @@
     set $P1, 'glut'
     _lua__GLOBAL[$P1] = _glut
 
-    $P2 = split ' ', 'CreateWindow DestroyWindow DisplayFunc IdleFunc Init 
InitDisplayMode InitWindowSize KeyboardFunc MainLoop PostRedisplay ReshapeFunc 
SwapBuffers'
+    $P2 = split "\n", <<'LIST'
+CreateWindow
+DestroyWindow
+DisplayFunc
+IdleFunc
+Init
+InitDisplayMode
+InitWindowSize
+KeyboardFunc
+MainLoop
+PostRedisplay
+ReshapeFunc
+SwapBuffers
+LIST
     lua_register($P1, _glut, $P2)
 
     .return (_glut)

Modified: branches/opengl4lua/languages/lua/src/lib/lfs.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/lfs.pir   (original)
+++ branches/opengl4lua/languages/lua/src/lib/lfs.pir   Fri Aug  8 23:36:03 2008
@@ -44,7 +44,18 @@
     set $P1, 'lfs'
     _lua__GLOBAL[$P1] = _lfs
 
-    $P2 = split ' ', 'attributes chdir currentdir dir lock mkdir rmdir 
symlinkattributes touch unlock'
+    $P2 = split "\n", <<'LIST'
+attributes
+chdir
+currentdir
+dir
+lock
+mkdir
+rmdir
+symlinkattributes
+touch
+unlock
+LIST
     lua_register($P1, _lfs, $P2)
 
     new $P2, 'LuaString'

Modified: branches/opengl4lua/languages/lua/src/lib/luaaux.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luaaux.pir        (original)
+++ branches/opengl4lua/languages/lua/src/lib/luaaux.pir        Fri Aug  8 
23:36:03 2008
@@ -805,6 +805,7 @@
   L3:
     unless names goto L4
     $S0 = shift names
+    unless $S0 goto L3
     $P0 = ns[$S0]
     $P0.'setfenv'(env)
     set $P1, $S0

Modified: branches/opengl4lua/languages/lua/src/lib/luabasic.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luabasic.pir      (original)
+++ branches/opengl4lua/languages/lua/src/lib/luabasic.pir      Fri Aug  8 
23:36:03 2008
@@ -49,7 +49,33 @@
     set $P1, '_G'
     _lua__GLOBAL[$P1] = _lua__GLOBAL
 
-    $P2 = split ' ', 'assert collectgarbage dofile error getfenv getmetatable 
ipairs load loadfile loadstring next pairs pcall print rawequal rawget rawset 
select setfenv setmetatable tonumber tostring type unpack xpcall'
+    $P2 = split "\n", <<'LIST'
+assert
+collectgarbage
+dofile
+error
+getfenv
+getmetatable
+ipairs
+load
+loadfile
+loadstring
+next
+pairs
+pcall
+print
+rawequal
+rawget
+rawset
+select
+setfenv
+setmetatable
+tonumber
+tostring
+type
+unpack
+xpcall
+LIST
     lua_register($P1, _lua__GLOBAL, $P2)
 
 =item C<_VERSION>

Modified: branches/opengl4lua/languages/lua/src/lib/luacoroutine.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luacoroutine.pir  (original)
+++ branches/opengl4lua/languages/lua/src/lib/luacoroutine.pir  Fri Aug  8 
23:36:03 2008
@@ -36,7 +36,14 @@
     set $P1, 'coroutine'
     _lua__GLOBAL[$P1] = _coroutine
 
-    $P2 = split ' ', 'create resume running status wrap yield'
+    $P2 = split "\n", <<'LIST'
+create
+resume
+running
+status
+wrap
+yield
+LIST
     lua_register($P1, _coroutine, $P2)
 
     new $P0, 'ResizablePMCArray'

Modified: branches/opengl4lua/languages/lua/src/lib/luadebug.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luadebug.pir      (original)
+++ branches/opengl4lua/languages/lua/src/lib/luadebug.pir      Fri Aug  8 
23:36:03 2008
@@ -43,7 +43,22 @@
     set $P1, 'debug'
     _lua__GLOBAL[$P1] = _debug
 
-    $P2 = split ' ', 'debug getfenv gethook getinfo getlocal getmetatable 
getregistry getupvalue setfenv sethook setlocal setmetatable setupvalue 
traceback'
+    $P2 = split "\n", <<'LIST'
+debug
+getfenv
+gethook
+getinfo
+getlocal
+getmetatable
+getregistry
+getupvalue
+setfenv
+sethook
+setlocal
+setmetatable
+setupvalue
+traceback
+LIST
     lua_register($P1, _debug, $P2)
 
 .end

Modified: branches/opengl4lua/languages/lua/src/lib/luafile.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luafile.pir       (original)
+++ branches/opengl4lua/languages/lua/src/lib/luafile.pir       Fri Aug  8 
23:36:03 2008
@@ -29,7 +29,17 @@
     set $P1, '__index'
     _file[$P1] = _file
 
-    $P2 = split ' ', 'close flush lines read seek setvbuf write __gc 
__tostring'
+    $P2 = split "\n", <<'LIST'
+close
+flush
+lines
+read
+seek
+setvbuf
+write
+__gc
+__tostring
+LIST
     null $P0
     lua_register($P0, _file, $P2)
 

Modified: branches/opengl4lua/languages/lua/src/lib/luaio.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luaio.pir (original)
+++ branches/opengl4lua/languages/lua/src/lib/luaio.pir Fri Aug  8 23:36:03 2008
@@ -53,7 +53,20 @@
     set $P1, 'io'
     _lua__GLOBAL[$P1] = _io
 
-    $P2 = split ' ', 'close flush input lines open output popen read tmpfile 
type write readline'
+    $P2 = split "\n", <<'LIST'
+close
+flush
+input
+lines
+open
+output
+popen
+read
+tmpfile
+type
+write
+readline
+LIST
     lua_register($P1, _io, $P2, _io_env)
 
     .const .Sub _readline = 'readline'

Modified: branches/opengl4lua/languages/lua/src/lib/luamath.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luamath.pir       (original)
+++ branches/opengl4lua/languages/lua/src/lib/luamath.pir       Fri Aug  8 
23:36:03 2008
@@ -62,7 +62,33 @@
     set $P1, 'math'
     _lua__GLOBAL[$P1] = _math
 
-    $P2 = split ' ', 'abs acos asin atan atan2 ceil cos deg exp floor fmod 
frexp ldexp log log10 max min modf pow rad random randomseed sin sqrt tan'
+    $P2 = split "\n", <<'LIST'
+abs
+acos
+asin
+atan
+atan2
+ceil
+cos
+deg
+exp
+floor
+fmod
+frexp
+ldexp
+log
+log10
+max
+min
+modf
+pow
+rad
+random
+randomseed
+sin
+sqrt
+tan
+LIST
     lua_register($P1, _math, $P2)
 
     # LUA_COMPAT_MOD

Modified: branches/opengl4lua/languages/lua/src/lib/luaos.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luaos.pir (original)
+++ branches/opengl4lua/languages/lua/src/lib/luaos.pir Fri Aug  8 23:36:03 2008
@@ -33,7 +33,19 @@
     set $P1, 'os'
     _lua__GLOBAL[$P1] = _os
 
-    $P2 = split ' ', 'clock date difftime execute exit getenv remove rename 
setlocale time tmpname'
+    $P2 = split "\n", <<'LIST'
+clock
+date
+difftime
+execute
+exit
+getenv
+remove
+rename
+setlocale
+time
+tmpname
+LIST
     lua_register($P1, _os, $P2)
 
 .end

Modified: branches/opengl4lua/languages/lua/src/lib/luapackage.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luapackage.pir    (original)
+++ branches/opengl4lua/languages/lua/src/lib/luapackage.pir    Fri Aug  8 
23:36:03 2008
@@ -32,7 +32,10 @@
     set $P1, 'package'
     _lua__GLOBAL[$P1] = _package
 
-    $P2 = split ' ', 'loadlib seeall'
+    $P2 = split "\n", <<'LIST'
+loadlib
+seeall
+LIST
     lua_register($P1, _package, $P2)
 
     # LUA_COMPAT_LOADLIB
@@ -76,7 +79,10 @@
     set $P1, 'preload'
     _package[$P1] = $P0
 
-    $P2 = split ' ', 'module require'
+    $P2 = split "\n", <<'LIST'
+module
+require
+LIST
     null $P0
     lua_register($P0, _lua__GLOBAL, $P2)
 

Modified: branches/opengl4lua/languages/lua/src/lib/luastring.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luastring.pir     (original)
+++ branches/opengl4lua/languages/lua/src/lib/luastring.pir     Fri Aug  8 
23:36:03 2008
@@ -44,7 +44,22 @@
     set $P1, 'string'
     _lua__GLOBAL[$P1] = _string
 
-    $P2 = split ' ', 'byte char dump find format gmatch gsub len lower match 
rep reverse sub upper'
+    $P2 = split "\n", <<'LIST'
+byte
+char
+dump
+find
+format
+gmatch
+gsub
+len
+lower
+match
+rep
+reverse
+sub
+upper
+LIST
     lua_register($P1, _string, $P2)
 
     # LUA_COMPAT_GFIND

Modified: branches/opengl4lua/languages/lua/src/lib/luatable.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/luatable.pir      (original)
+++ branches/opengl4lua/languages/lua/src/lib/luatable.pir      Fri Aug  8 
23:36:03 2008
@@ -39,7 +39,17 @@
     _lua__GLOBAL[$P1] = _table
 
     # LUA_COMPAT_GETN
-    $P2 = split ' ', 'concat foreach foreachi getn insert maxn remove setn 
sort'
+    $P2 = split "\n", <<'LIST'
+concat
+foreach
+foreachi
+getn
+insert
+maxn
+remove
+setn
+sort
+LIST
     lua_register($P1, _table, $P2)
 
 .end

Modified: branches/opengl4lua/languages/lua/src/lib/md5.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/md5.pir   (original)
+++ branches/opengl4lua/languages/lua/src/lib/md5.pir   Fri Aug  8 23:36:03 2008
@@ -49,7 +49,14 @@
     set $P1, MYNAME
     _lua__GLOBAL[$P1] = _md5
 
-    $P2 = split ' ', 'clone digest new reset tostring update'
+    $P2 = split "\n", <<'LIST'
+clone
+digest
+new
+reset
+tostring
+update
+LIST
     lua_register($P1, _md5, $P2)
 
     set $P1, 'tostring'

Modified: branches/opengl4lua/languages/lua/src/lib/random.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/random.pir        (original)
+++ branches/opengl4lua/languages/lua/src/lib/random.pir        Fri Aug  8 
23:36:03 2008
@@ -48,7 +48,15 @@
     set $P1, MYNAME
     _lua__GLOBAL[$P1] = _random
 
-    $P2 = split ' ', 'clone new seed tostring value valuei valuex'
+    $P2 = split "\n", <<'LIST'
+clone
+new
+seed
+tostring
+value
+valuei
+valuex
+LIST
     lua_register($P1, _random, $P2)
 
     set $P1, 'tostring'

Modified: branches/opengl4lua/languages/lua/src/lib/uuid.pir
==============================================================================
--- branches/opengl4lua/languages/lua/src/lib/uuid.pir  (original)
+++ branches/opengl4lua/languages/lua/src/lib/uuid.pir  Fri Aug  8 23:36:03 2008
@@ -41,7 +41,11 @@
     set $P1, 'uuid'
     _lua__GLOBAL[$P1] = _uuid
 
-    $P2 = split ' ', 'isvalid new'
+    $P2 = split "\n", <<'LIST'
+isvalid
+new
+time
+LIST
     lua_register($P1, _uuid, $P2)
 
     # ???

Modified: branches/opengl4lua/languages/lua/src/yapp/Lua/build.pm
==============================================================================
--- branches/opengl4lua/languages/lua/src/yapp/Lua/build.pm     (original)
+++ branches/opengl4lua/languages/lua/src/yapp/Lua/build.pm     Fri Aug  8 
23:36:03 2008
@@ -896,8 +896,10 @@
     push @opcodes, @{ $e_start->[1] };
     push @opcodes, @{ $e_limit->[1] };
     push @opcodes, @{ $e_step->[1] };
-    my $_var = $var->[0];
+    my $_loc_v = $var->[0];
     push @opcodes, @{ $var->[1] };
+    my $_var = new_tmp( $parser, 'pmc', 'number' );
+    push @opcodes, new LocalDir( $parser, 'result' => $_var, );
     my $_limit = new_tmp( $parser, 'pmc', 'number' );
     push @opcodes, new LocalDir( $parser, 'result' => $_limit, );
     my $_step = new_tmp( $parser, 'pmc', 'number' );
@@ -940,7 +942,11 @@
         'result' => $lbl_end,
     );
     push @opcodes, new LabelOp( $parser, 'arg1' => $lbl_blk, );
-
+    push @opcodes, new CloneOp(
+        $parser,
+        'arg1'   => $_var,
+        'result' => $_loc_v,
+    );
     foreach my $op ( @{$block} ) {
         if ( $op and $op->isa('BranchOp') ) {
             if ( $op->{result} eq 'break' ) {

Reply via email to