diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1997-11-04 13:27:53 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1997-11-04 13:27:53 -0200 |
| commit | 45cad43c3fedb13a5e424429fe94dc78ba01a118 (patch) | |
| tree | e5dae021aa66accc06b6941add38bf2d495c6440 /lauxlib.c | |
| parent | dad5a01fb07e8a654f195ec3a9ca271cd5ee32e3 (diff) | |
| download | lua-45cad43c3fedb13a5e424429fe94dc78ba01a118.tar.gz lua-45cad43c3fedb13a5e424429fe94dc78ba01a118.tar.bz2 lua-45cad43c3fedb13a5e424429fe94dc78ba01a118.zip | |
"lua_open": now lua has an explicit open operation.
Diffstat (limited to 'lauxlib.c')
| -rw-r--r-- | lauxlib.c | 3 |
1 files changed, 2 insertions, 1 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lauxlib.c,v 1.1 1997/09/16 19:25:59 roberto Exp roberto $ | 2 | ** $Id: lauxlib.c,v 1.2 1997/09/26 15:02:26 roberto Exp roberto $ |
| 3 | ** Auxiliar functions for building Lua libraries | 3 | ** Auxiliar functions for building Lua libraries |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -67,6 +67,7 @@ lua_Object luaL_nonnullarg (int numArg) | |||
| 67 | void luaL_openlib (struct luaL_reg *l, int n) | 67 | void luaL_openlib (struct luaL_reg *l, int n) |
| 68 | { | 68 | { |
| 69 | int i; | 69 | int i; |
| 70 | lua_open(); /* make sure lua is already open */ | ||
| 70 | for (i=0; i<n; i++) | 71 | for (i=0; i<n; i++) |
| 71 | lua_register(l[i].name, l[i].func); | 72 | lua_register(l[i].name, l[i].func); |
| 72 | } | 73 | } |
