The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Classes | Macros | Typedefs
llimits.h File Reference
#include <limits.h>
#include <stddef.h>
#include "lua.h"
Include dependency graph for llimits.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

union  luai_Cast
 

Macros

#define MAX_SIZET   ((size_t)(~(size_t)0)-2)
 
#define MAX_LUMEM   ((lu_mem)(~(lu_mem)0)-2)
 
#define MAX_LMEM   ((l_mem) ((MAX_LUMEM >> 1) - 2))
 
#define MAX_INT   (INT_MAX-2) /* maximum value of an int (-2 for safety) */
 
#define IntPoint(p)   ((unsigned int)(lu_mem)(p))
 
#define LUAI_USER_ALIGNMENT_T   union { double u; void *s; long l; }
 
#define lua_assert(c)   ((void)0)
 
#define check_exp(c, e)   (e)
 
#define lua_longassert(c)   ((void)0)
 
#define luai_apicheck(L, e)   lua_assert(e)
 
#define api_check(l, e, msg)   luai_apicheck(l,(e) && msg)
 
#define UNUSED(x)   ((void)(x)) /* to avoid warnings */
 
#define cast(t, exp)   ((t)(exp))
 
#define cast_byte(i)   cast(lu_byte, (i))
 
#define cast_num(i)   cast(lua_Number, (i))
 
#define cast_int(i)   cast(int, (i))
 
#define cast_uchar(i)   cast(unsigned char, (i))
 
#define l_noret   void
 
#define LUAI_MAXCCALLS   200
 
#define MAXUPVAL   UCHAR_MAX
 
#define MAXSTACK   250
 
#define MINSTRTABSIZE   32
 
#define LUA_MINBUFFER   32
 
#define lua_lock(L)   ((void) 0)
 
#define lua_unlock(L)   ((void) 0)
 
#define luai_threadyield(L)   {lua_unlock(L); lua_lock(L);}
 
#define luai_userstateopen(L)   ((void)L)
 
#define luai_userstateclose(L)   ((void)L)
 
#define luai_userstatethread(L, L1)   ((void)L)
 
#define luai_userstatefree(L, L1)   ((void)L)
 
#define luai_userstateresume(L, n)   ((void)L)
 
#define luai_userstateyield(L, n)   ((void)L)
 
#define LUAI_EXTRAIEEE   static const union luai_Cast ieeeendian = {-(33.0 + 6755399441055744.0)};
 
#define LUA_IEEEENDIANLOC   (ieeeendian.l_p[1] == 33)
 
#define lua_number2int32(i, n, t)
 
#define luai_hashnum(i, n)
 
#define lua_number2int(i, n)   lua_number2int32(i, n, int)
 
#define lua_number2unsigned(i, n)   lua_number2int32(i, n, lua_Unsigned)
 
#define lua_number2integer(i, n)   lua_number2int32(i, n, lua_Integer)
 
#define lua_unsigned2number(u)   (((u) <= (lua_Unsigned)INT_MAX) ? (lua_Number)(int)(u) : (lua_Number)(u))
 
#define condmovestack(L)   ((void)0)
 
#define condchangemem(L)   condmovestack(L)
 

Typedefs

typedef unsigned LUA_INT32 lu_int32
 
typedef LUAI_UMEM lu_mem
 
typedef LUAI_MEM l_mem
 
typedef unsigned char lu_byte
 
typedef LUAI_USER_ALIGNMENT_T L_Umaxalign
 
typedef LUAI_UACNUMBER l_uacNumber
 
typedef lu_int32 Instruction
 

Macro Definition Documentation

#define api_check (   l,
  e,
  msg 
)    luai_apicheck(l,(e) && msg)
#define cast (   t,
  exp 
)    ((t)(exp))
#define cast_byte (   i)    cast(lu_byte, (i))
#define cast_int (   i)    cast(int, (i))
#define cast_num (   i)    cast(lua_Number, (i))
#define cast_uchar (   i)    cast(unsigned char, (i))

Definition at line 97 of file llimits.h.

Referenced by lua_strx2number(), luaO_str2d(), luaZ_fill(), and readhexa().

#define check_exp (   c,
  e 
)    (e)

Definition at line 66 of file llimits.h.

Referenced by luaK_indexed(), and upvalname().

#define condchangemem (   L)    condmovestack(L)

Definition at line 302 of file llimits.h.

#define condmovestack (   L)    ((void)0)

Definition at line 295 of file llimits.h.

Referenced by luaD_shrinkstack().

#define IntPoint (   p)    ((unsigned int)(lu_mem)(p))

Definition at line 43 of file llimits.h.

#define l_noret   void

Definition at line 108 of file llimits.h.

#define lua_assert (   c)    ((void)0)

Definition at line 65 of file llimits.h.

Referenced by adjust_varargs(), anchor_token(), atomic(), close_func(), close_state(), closegoto(), codeextraarg(), codenot(), computesizes(), constructor(), currentpc(), discharge2reg(), DumpConstants(), enterblock(), entersweep(), exp1(), f_parser(), finishCcall(), fixjump(), freeobj(), freereg(), funcargs(), generationalcollection(), getlocvar(), gmatch_aux(), hookf(), inclinenumber(), invertjump(), io_readline(), leaveblock(), LoadConstants(), lua_getinfo(), lua_resume(), lua_yieldk(), luaC_barrier_(), luaC_barrierback_(), luaC_barrierproto_(), luaC_checkfinalizer(), luaC_checkupvalcolor(), luaC_freeallobjects(), luaC_fullgc(), luaD_hook(), luaD_precall(), luaD_reallocstack(), luaE_extendCI(), luaE_freethread(), luaF_close(), luaF_findupval(), luaG_concaterror(), luaH_getstr(), luaH_newkey(), luaK_codeABC(), luaK_codeABx(), luaK_indexed(), luaK_patchclose(), luaK_patchlist(), luaK_posfix(), luaK_prefix(), luaK_setlist(), luaK_storevar(), luaM_realloc_(), luaO_arith(), luaS_eqlngstr(), luaS_resize(), luaT_gettm(), luaV_concat(), luaV_equalobj_(), luaV_execute(), luaV_finishOp(), luaX_lookahead(), luaX_token2str(), luaY_parser(), makeseed(), propagatelist(), propagatemark(), read_numeral(), reallymarkobject(), removeentry(), resume(), retstat(), runargs(), separatetobefnz(), singlestep(), singlevar(), skip_sep(), stackinuse(), statement(), str_find_aux(), str_gsub(), tofile(), traversestrongtable(), traverseweakvalue(), udata2finalize(), and unlinkupval().

#define LUA_IEEEENDIANLOC   (ieeeendian.l_p[1] == 33)

Definition at line 220 of file llimits.h.

Referenced by lua_round3().

#define lua_lock (   L)    ((void) 0)
#define lua_longassert (   c)    ((void)0)

Definition at line 67 of file llimits.h.

#define LUA_MINBUFFER   32

Definition at line 149 of file llimits.h.

Referenced by luaX_setinput(), and luaZ_openspace().

#define lua_number2int (   i,
  n 
)    lua_number2int32(i, n, int)

Definition at line 235 of file llimits.h.

Referenced by addk(), arrayindex(), lua_round2(), and luaH_get().

#define lua_number2int32 (   i,
  n,
  t 
)
Value:
{ LUAI_EXTRAIEEE \
volatile union luai_Cast u; u.l_d = (n) + 6755399441055744.0; \
(i) = (t)u.l_p[LUA_IEEEENDIANLOC]; }
GLdouble GLdouble t
Definition: glew.h:1366
double l_d
Definition: llimits.h:215
#define LUA_IEEEENDIANLOC
Definition: llimits.h:220
size_t i
Definition: function.cpp:1057
GLclampd n
Definition: glew.h:5903

Definition at line 226 of file llimits.h.

#define lua_number2integer (   i,
  n 
)    lua_number2int32(i, n, lua_Integer)

Definition at line 240 of file llimits.h.

Referenced by lua_tointegerx().

#define lua_number2unsigned (   i,
  n 
)    lua_number2int32(i, n, lua_Unsigned)

Definition at line 236 of file llimits.h.

Referenced by lua_tounsignedx().

#define lua_unlock (   L)    ((void) 0)
#define lua_unsigned2number (   u)    (((u) <= (lua_Unsigned)INT_MAX) ? (lua_Number)(int)(u) : (lua_Number)(u))

Definition at line 272 of file llimits.h.

Referenced by lua_pushunsigned().

#define luai_apicheck (   L,
  e 
)    lua_assert(e)

Definition at line 79 of file llimits.h.

#define LUAI_EXTRAIEEE   static const union luai_Cast ieeeendian = {-(33.0 + 6755399441055744.0)};

Definition at line 218 of file llimits.h.

Referenced by lua_round3().

#define luai_hashnum (   i,
  n 
)
Value:
{ volatile union luai_Cast u; u.l_d = (n) + 1.0; /* avoid -0 */ \
(i) = u.l_p[0]; (i) += u.l_p[1]; } /* add double bits for his hash */
double l_d
Definition: llimits.h:215
size_t i
Definition: function.cpp:1057
GLclampd n
Definition: glew.h:5903

Definition at line 231 of file llimits.h.

Referenced by hashnum().

#define LUAI_MAXCCALLS   200

Definition at line 118 of file llimits.h.

Referenced by assignment(), enterlevel(), luaD_call(), and resume().

#define luai_threadyield (   L)    {lua_unlock(L); lua_lock(L);}

Definition at line 159 of file llimits.h.

#define LUAI_USER_ALIGNMENT_T   union { double u; void *s; long l; }

Definition at line 49 of file llimits.h.

#define luai_userstateclose (   L)    ((void)L)

Definition at line 173 of file llimits.h.

Referenced by close_state().

#define luai_userstatefree (   L,
  L1 
)    ((void)L)

Definition at line 181 of file llimits.h.

Referenced by luaE_freethread().

#define luai_userstateopen (   L)    ((void)L)

Definition at line 169 of file llimits.h.

Referenced by f_luaopen().

#define luai_userstateresume (   L,
  n 
)    ((void)L)

Definition at line 185 of file llimits.h.

Referenced by lua_resume().

#define luai_userstatethread (   L,
  L1 
)    ((void)L)

Definition at line 177 of file llimits.h.

Referenced by lua_newthread().

#define luai_userstateyield (   L,
  n 
)    ((void)L)

Definition at line 189 of file llimits.h.

Referenced by lua_yieldk().

#define MAX_INT   (INT_MAX-2) /* maximum value of an int (-2 for safety) */
#define MAX_LMEM   ((l_mem) ((MAX_LUMEM >> 1) - 2))

Definition at line 33 of file llimits.h.

Referenced by incstep(), and setpause().

#define MAX_LUMEM   ((lu_mem)(~(lu_mem)0)-2)

Definition at line 31 of file llimits.h.

#define MAX_SIZET   ((size_t)(~(size_t)0)-2)

Definition at line 29 of file llimits.h.

Referenced by luaS_newlstr(), luaS_newudata(), luaV_concat(), and save().

#define MAXSTACK   250

Definition at line 137 of file llimits.h.

Referenced by luaK_checkstack().

#define MAXUPVAL   UCHAR_MAX

Definition at line 125 of file llimits.h.

Referenced by index2addr(), lua_pushcclosure(), and newupvalue().

#define MINSTRTABSIZE   32

Definition at line 143 of file llimits.h.

Referenced by f_luaopen().

#define UNUSED (   x)    ((void)(x)) /* to avoid warnings */

Definition at line 88 of file llimits.h.

Typedef Documentation

Definition at line 132 of file llimits.h.

typedef LUAI_MEM l_mem

Definition at line 21 of file llimits.h.

Definition at line 56 of file llimits.h.

Definition at line 52 of file llimits.h.

typedef unsigned char lu_byte

Definition at line 26 of file llimits.h.

typedef unsigned LUA_INT32 lu_int32

Definition at line 17 of file llimits.h.

typedef LUAI_UMEM lu_mem

Definition at line 19 of file llimits.h.