aboutsummaryrefslogtreecommitdiff
path: root/lobject.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2013-06-25 15:58:32 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2013-06-25 15:58:32 -0300
commite39da66c8c23ede187df14fef6314052d124dad3 (patch)
treec4dee44027c2818daf1d35abf0e209ec6fb1bc0d /lobject.c
parent483c2ccd0feb881947d2e2ce5177d0061d87adad (diff)
downloadlua-e39da66c8c23ede187df14fef6314052d124dad3.tar.gz
lua-e39da66c8c23ede187df14fef6314052d124dad3.tar.bz2
lua-e39da66c8c23ede187df14fef6314052d124dad3.zip
macro 'lua_strx2number' does not need to be global
Diffstat (limited to 'lobject.c')
-rw-r--r--lobject.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/lobject.c b/lobject.c
index 0d66110c..dcd81a96 100644
--- a/lobject.c
+++ b/lobject.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lobject.c,v 2.65 2013/05/27 17:42:38 roberto Exp roberto $ 2** $Id: lobject.c,v 2.66 2013/06/04 19:36:42 roberto Exp roberto $
3** Some generic functions over Lua objects 3** Some generic functions over Lua objects
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -140,6 +140,18 @@ static int isneg (const char **s) {
140} 140}
141 141
142 142
143/*
144** lua_strx2number converts an hexadecimal numeric string to a number.
145** In C99, 'strtod' does both conversions. C89, however, has no function
146** to convert floating hexadecimal strings to numbers. For these
147** systems, you can leave 'lua_strx2number' undefined and Lua will
148** provide its own implementation.
149*/
150#if defined(LUA_USE_STRTODHEX)
151#define lua_strx2number(s,p) lua_str2number(s,p)
152#endif
153
154
143#if !defined(lua_strx2number) 155#if !defined(lua_strx2number)
144 156
145#include <math.h> 157#include <math.h>