diff options
Diffstat (limited to 'llimits.h')
-rw-r--r-- | llimits.h | 16 |
1 files changed, 3 insertions, 13 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: llimits.h,v 1.19 2000/10/26 12:47:05 roberto Exp roberto $ | 2 | ** $Id: llimits.h,v 1.20 2000/11/24 17:39:56 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 | */ |
@@ -31,21 +31,11 @@ | |||
31 | #endif | 31 | #endif |
32 | 32 | ||
33 | 33 | ||
34 | /* | 34 | /* function to convert a lua_Number to a string */ |
35 | ** Define the type `number' of Lua | ||
36 | ** GREP LUA_NUMBER to change that | ||
37 | */ | ||
38 | #ifndef LUA_NUM_TYPE | ||
39 | #define LUA_NUM_TYPE double | ||
40 | #endif | ||
41 | |||
42 | typedef LUA_NUM_TYPE Number; | ||
43 | |||
44 | /* function to convert a Number to a string */ | ||
45 | #define NUMBER_FMT "%.16g" /* LUA_NUMBER */ | 35 | #define NUMBER_FMT "%.16g" /* LUA_NUMBER */ |
46 | #define lua_number2str(s,n) sprintf((s), NUMBER_FMT, (n)) | 36 | #define lua_number2str(s,n) sprintf((s), NUMBER_FMT, (n)) |
47 | 37 | ||
48 | /* function to convert a string to a Number */ | 38 | /* function to convert a string to a lua_Number */ |
49 | #define lua_str2number(s,p) strtod((s), (p)) | 39 | #define lua_str2number(s,p) strtod((s), (p)) |
50 | 40 | ||
51 | 41 | ||