mirror of
https://github.com/LuaJIT/LuaJIT.git
synced 2025-02-07 23:24:09 +00:00
Avoid name clash with Windows MM_MAX define.
This commit is contained in:
parent
16369d5a64
commit
87553d9e77
@ -204,7 +204,7 @@ static const char *getfuncname(lua_State *L, TValue *frame, const char **name)
|
|||||||
BCReg slot = bc_a(*ip);
|
BCReg slot = bc_a(*ip);
|
||||||
if (bc_op(*ip) == BC_ITERC) slot -= 3;
|
if (bc_op(*ip) == BC_ITERC) slot -= 3;
|
||||||
return getobjname(funcproto(fn), ip, slot, name);
|
return getobjname(funcproto(fn), ip, slot, name);
|
||||||
} else if (mm != MM_MAX) {
|
} else if (mm != MM__MAX) {
|
||||||
*name = strdata(mmname_str(G(L), mm));
|
*name = strdata(mmname_str(G(L), mm));
|
||||||
return "metamethod";
|
return "metamethod";
|
||||||
} else {
|
} else {
|
||||||
|
@ -459,15 +459,15 @@ typedef enum {
|
|||||||
#define MMENUM(name) MM_##name,
|
#define MMENUM(name) MM_##name,
|
||||||
MMDEF(MMENUM)
|
MMDEF(MMENUM)
|
||||||
#undef MMENUM
|
#undef MMENUM
|
||||||
MM_MAX,
|
MM__MAX,
|
||||||
MM____ = MM_MAX,
|
MM____ = MM__MAX,
|
||||||
MM_FAST = MM_eq
|
MM_FAST = MM_eq
|
||||||
} MMS;
|
} MMS;
|
||||||
|
|
||||||
/* GC root IDs. */
|
/* GC root IDs. */
|
||||||
typedef enum {
|
typedef enum {
|
||||||
GCROOT_MMNAME, /* Metamethod names. */
|
GCROOT_MMNAME, /* Metamethod names. */
|
||||||
GCROOT_MMNAME_LAST = GCROOT_MMNAME + MM_MAX-1,
|
GCROOT_MMNAME_LAST = GCROOT_MMNAME + MM__MAX-1,
|
||||||
GCROOT_BASEMT, /* Metatables for base types. */
|
GCROOT_BASEMT, /* Metatables for base types. */
|
||||||
GCROOT_BASEMT_NUM = GCROOT_BASEMT + ~LJ_TNUMX,
|
GCROOT_BASEMT_NUM = GCROOT_BASEMT + ~LJ_TNUMX,
|
||||||
GCROOT_IO_INPUT, /* Userdata for default I/O input file. */
|
GCROOT_IO_INPUT, /* Userdata for default I/O input file. */
|
||||||
|
Loading…
Reference in New Issue
Block a user