aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2014-04-11 16:53:45 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2014-04-11 16:53:45 -0300
commitd99ffa920dadc8ff9ef8cade2436e26d8fa9a6b2 (patch)
treeeae768fa49737e314e36e038bcda791a5fb45ccb
parent2771050dfa0fe6b2b679a9f91749a1ab19cfe7dd (diff)
downloadlua-d99ffa920dadc8ff9ef8cade2436e26d8fa9a6b2.tar.gz
lua-d99ffa920dadc8ff9ef8cade2436e26d8fa9a6b2.tar.bz2
lua-d99ffa920dadc8ff9ef8cade2436e26d8fa9a6b2.zip
new type 'LUAI_UACINT' (result of an 'usual argument conversion' of
a lua_Integer)
-rw-r--r--lobject.c4
-rw-r--r--luaconf.h6
2 files changed, 7 insertions, 3 deletions
diff --git a/lobject.c b/lobject.c
index 3bc942a9..4e8b1d8e 100644
--- a/lobject.c
+++ b/lobject.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lobject.c,v 2.76 2014/03/21 13:52:33 roberto Exp roberto $ 2** $Id: lobject.c,v 2.77 2014/04/09 17:05:11 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*/
@@ -346,7 +346,7 @@ const char *luaO_pushvfstring (lua_State *L, const char *fmt, va_list argp) {
346 break; 346 break;
347 } 347 }
348 case 'I': { 348 case 'I': {
349 setivalue(L->top++, cast_integer(va_arg(argp, lua_Integer))); 349 setivalue(L->top++, cast_integer(va_arg(argp, l_uacInt)));
350 break; 350 break;
351 } 351 }
352 case 'f': { 352 case 'f': {
diff --git a/luaconf.h b/luaconf.h
index cbedd587..68a02fc4 100644
--- a/luaconf.h
+++ b/luaconf.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: luaconf.h,v 1.194 2014/04/03 14:18:02 roberto Exp $ 2** $Id: luaconf.h,v 1.195 2014/04/09 17:05:11 roberto Exp roberto $
3** Configuration file for Lua 3** Configuration file for Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -529,6 +529,8 @@
529** 529**
530@@ LUA_UNSIGNED is the unsigned version of LUA_INTEGER. 530@@ LUA_UNSIGNED is the unsigned version of LUA_INTEGER.
531** 531**
532@@ LUAI_UACINT is the result of an 'usual argument conversion'
533@* over a lUA_INTEGER.
532@@ LUA_INTEGER_FRMLEN is the length modifier for reading/writing integers. 534@@ LUA_INTEGER_FRMLEN is the length modifier for reading/writing integers.
533@@ LUA_INTEGER_SCAN is the format for reading integers. 535@@ LUA_INTEGER_SCAN is the format for reading integers.
534@@ LUA_INTEGER_FMT is the format for writing integers. 536@@ LUA_INTEGER_FMT is the format for writing integers.
@@ -573,6 +575,8 @@
573#define LUA_MAXINTEGER ((LUA_INTEGER)(~(LUA_UNSIGNED)0 >> 1)) 575#define LUA_MAXINTEGER ((LUA_INTEGER)(~(LUA_UNSIGNED)0 >> 1))
574#define LUA_MININTEGER ((LUA_INTEGER)~(~(LUA_UNSIGNED)0 >> 1)) 576#define LUA_MININTEGER ((LUA_INTEGER)~(~(LUA_UNSIGNED)0 >> 1))
575 577
578#define LUAI_UACINT LUA_INTEGER
579
576/* }================================================================== */ 580/* }================================================================== */
577 581
578 582