diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-10-06 16:28:47 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2000-10-06 16:28:47 -0300 |
commit | cd3d44695775631271d9d038247fe64092f13f33 (patch) | |
tree | 34008ca2cb4cca0e3702930c9bc87ad693aeec70 | |
parent | f01e6c6f1dc8e82faa782020556de9073b683be7 (diff) | |
download | lua-cd3d44695775631271d9d038247fe64092f13f33.tar.gz lua-cd3d44695775631271d9d038247fe64092f13f33.tar.bz2 lua-cd3d44695775631271d9d038247fe64092f13f33.zip |
detail
-rw-r--r-- | llimits.h | 5 | ||||
-rw-r--r-- | lstate.c | 4 |
2 files changed, 5 insertions, 4 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: llimits.h,v 1.15 2000/09/29 12:42:13 roberto Exp roberto $ | 2 | ** $Id: llimits.h,v 1.16 2000/10/03 14:03:21 roberto Exp roberto $ |
3 | ** Limits, basic types, and some other "installation-dependent" definitions | 3 | ** Limits, basic types, and some other "installation-dependent" definitions |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -42,7 +42,8 @@ | |||
42 | typedef LUA_NUM_TYPE Number; | 42 | typedef LUA_NUM_TYPE Number; |
43 | 43 | ||
44 | /* function to convert a Number to a string */ | 44 | /* function to convert a Number to a string */ |
45 | #define lua_number2str(s,n) sprintf((s), "%.16g", (n)) | 45 | #define NUMBER_FMT "%.16g" /* LUA_NUMBER */ |
46 | #define lua_number2str(s,n) sprintf((s), NUMBER_FMT, (n)) | ||
46 | 47 | ||
47 | /* function to convert a string to a Number */ | 48 | /* function to convert a string to a Number */ |
48 | #define lua_str2number(s,p) strtod((s), (p)) | 49 | #define lua_str2number(s,p) strtod((s), (p)) |
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lstate.c,v 1.42 2000/09/29 12:42:13 roberto Exp roberto $ | 2 | ** $Id: lstate.c,v 1.43 2000/10/05 13:00:17 roberto Exp roberto $ |
3 | ** Global State | 3 | ** Global State |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -89,7 +89,7 @@ lua_State *lua_open (int stacksize) { | |||
89 | lua_close(L); | 89 | lua_close(L); |
90 | return NULL; | 90 | return NULL; |
91 | } | 91 | } |
92 | L->GCthreshold = L->nblocks*4; | 92 | L->GCthreshold = 2*L->nblocks; |
93 | return L; | 93 | return L; |
94 | } | 94 | } |
95 | 95 | ||