mirror of
https://github.com/lua/lua.git
synced 2025-01-14 05:43:00 +08:00
more options moved from luaconf.h into internal files
This commit is contained in:
parent
e0f9d1c8f5
commit
46f1429936
34
llimits.h
34
llimits.h
@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: llimits.h,v 1.75 2009/11/17 11:56:03 roberto Exp roberto $
|
||||
** $Id: llimits.h,v 1.76 2009/12/17 12:26:09 roberto Exp roberto $
|
||||
** Limits, basic types, and some other `installation-dependent' definitions
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@ -133,6 +133,38 @@ typedef lu_int32 Instruction;
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
** these macros allow user-specific actions on threads when you defined
|
||||
** LUAI_EXTRASPACE and need to do something extra when a thread is
|
||||
** created/deleted/resumed/yielded.
|
||||
*/
|
||||
#if !defined(luai_userstateopen)
|
||||
#define luai_userstateopen(L) ((void)L)
|
||||
#endif
|
||||
|
||||
#if !defined(luai_userstateclose)
|
||||
#define luai_userstateclose(L) ((void)L)
|
||||
#endif
|
||||
|
||||
#if !defined(luai_userstatethread)
|
||||
#define luai_userstatethread(L,L1) ((void)L)
|
||||
#endif
|
||||
|
||||
#if !defined(luai_userstatefree)
|
||||
#define luai_userstatefree(L) ((void)L)
|
||||
#endif
|
||||
|
||||
#if !defined(luai_userstateresume)
|
||||
#define luai_userstateresume(L,n) ((void)L)
|
||||
#endif
|
||||
|
||||
#if !defined(luai_userstateyield)
|
||||
#define luai_userstateyield(L,n) ((void)L)
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
** macro to control inclusion of some hard tests on stack reallocation
|
||||
*/
|
||||
|
20
lstrlib.c
20
lstrlib.c
@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: lstrlib.c,v 1.145 2009/11/26 16:49:28 roberto Exp roberto $
|
||||
** $Id: lstrlib.c,v 1.146 2009/12/17 12:26:09 roberto Exp roberto $
|
||||
** Standard library for string operations and pattern-matching
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@ -698,6 +698,24 @@ static int str_gsub (lua_State *L) {
|
||||
/* }====================================================== */
|
||||
|
||||
|
||||
/*
|
||||
** length modifier for integer conversions ** in 'string.format' and
|
||||
** integer type corresponding to the previous length
|
||||
*/
|
||||
|
||||
#if defined(LUA_USELONGLONG)
|
||||
|
||||
#define LUA_INTFRMLEN "ll"
|
||||
#define LUA_INTFRM_T long long
|
||||
|
||||
#else
|
||||
|
||||
#define LUA_INTFRMLEN "l"
|
||||
#define LUA_INTFRM_T long
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/* maximum size of each formatted item (> len(format('%99.99f', -1e308))) */
|
||||
#define MAX_ITEM 512
|
||||
/* valid flags in a format specification */
|
||||
|
35
luaconf.h
35
luaconf.h
@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: luaconf.h,v 1.121 2009/12/14 15:27:30 roberto Exp roberto $
|
||||
** $Id: luaconf.h,v 1.122 2009/12/17 12:26:09 roberto Exp roberto $
|
||||
** Configuration file for Lua
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@ -524,39 +524,6 @@ union luai_Cast { double l_d; long l_l; };
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
@@ luai_userstate* allow user-specific actions on threads.
|
||||
** CHANGE them if you defined LUAI_EXTRASPACE and need to do something
|
||||
** extra when a thread is created/deleted/resumed/yielded.
|
||||
*/
|
||||
#define luai_userstateopen(L) ((void)L)
|
||||
#define luai_userstateclose(L) ((void)L)
|
||||
#define luai_userstatethread(L,L1) ((void)L)
|
||||
#define luai_userstatefree(L) ((void)L)
|
||||
#define luai_userstateresume(L,n) ((void)L)
|
||||
#define luai_userstateyield(L,n) ((void)L)
|
||||
|
||||
|
||||
/*
|
||||
@@ LUA_INTFRMLEN is the length modifier for integer conversions
|
||||
@* in 'string.format'.
|
||||
@@ LUA_INTFRM_T is the integer type corresponding to the previous length
|
||||
@* modifier.
|
||||
** CHANGE them if your system supports long long or does not support long.
|
||||
*/
|
||||
|
||||
#if defined(LUA_USELONGLONG)
|
||||
|
||||
#define LUA_INTFRMLEN "ll"
|
||||
#define LUA_INTFRM_T long long
|
||||
|
||||
#else
|
||||
|
||||
#define LUA_INTFRMLEN "l"
|
||||
#define LUA_INTFRM_T long
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
/* =================================================================== */
|
||||
|
Loading…
x
Reference in New Issue
Block a user