Skip to content
This repository has been archived by the owner on Jun 9, 2018. It is now read-only.

Commit

Permalink
OS becomes a dynpmc, so load it
Browse files Browse the repository at this point in the history
  • Loading branch information
fperrad committed May 5, 2010
1 parent f2bd831 commit bd7eedd
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions lua/lib/luaaux.pir
Expand Up @@ -693,6 +693,7 @@ This function only loads the chunk; it does not run it.
pbcname .= '.pbc'
$I0 = stat pbcname, .STAT_EXISTS
unless $I0 goto L3
$P0 = loadlib 'os'
new $P0, 'OS'
$S0 = $P0.'cwd'()
$S0 .= '/'
Expand Down
1 change: 1 addition & 0 deletions lua/lib/luaos.pir
Expand Up @@ -22,6 +22,7 @@ L<http://www.lua.org/manual/5.1/manual.html#5.8>.

.sub 'luaopen_os'
# print "init Lua OS\n"
$P0 = loadlib 'os'

.local pmc _lua__GLOBAL
_lua__GLOBAL = get_hll_global '_G'
Expand Down
1 change: 1 addition & 0 deletions lua/lib/luaperl.pir
Expand Up @@ -30,6 +30,7 @@ It's a temporary work. Waiting for the real PIR compiler/interpreter.
.namespace []
.sub '__onload' :anon :load
$P0 = loadlib 'os'
$P0 = newclass [ 'Lua'; 'PerlCompiler' ]
new $P1, $P0
compreg 'lua', $P1
Expand Down
1 change: 1 addition & 0 deletions t/env.t
Expand Up @@ -13,6 +13,7 @@
=cut

.sub 'main' :main
$P0 = loadlib 'os'
.include 'test_more.pir'

$P0 = new 'FileHandle'
Expand Down
1 change: 1 addition & 0 deletions t/lexico.t
Expand Up @@ -16,6 +16,7 @@ L<http://www.lua.org/manual/5.1/manual.html#2.1>.
=cut

.sub 'main' :main
$P0 = loadlib 'os'
.include 'test_more.pir'

plan(3)
Expand Down
1 change: 1 addition & 0 deletions t/luad.t
Expand Up @@ -19,6 +19,7 @@ by Kein-Hong Man
=cut

.sub 'main' :main
$P0 = loadlib 'os'
.include 'test_more.pir'

$P0 = open 'luac -v', 'rp'
Expand Down
1 change: 1 addition & 0 deletions t/test_lex.t
Expand Up @@ -19,6 +19,7 @@ L<http://www.lua.org/manual/5.1/manual.html#2.1>.
=cut

.sub 'main' :main
$P0 = loadlib 'os'
.include 'test_more.pir'

plan(23)
Expand Down

0 comments on commit bd7eedd

Please sign in to comment.