diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2001-02-06 14:01:29 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2001-02-06 14:01:29 -0200 |
commit | 1f917e709ca3fe41cf07fd4bf99a080883521394 (patch) | |
tree | 00e89f7218a38e028bebe111dbf682925fe4cca0 /ltests.h | |
parent | d444153dbea006f5e0547f27a11256af96ba1829 (diff) | |
download | lua-github-1f917e709ca3fe41cf07fd4bf99a080883521394.tar.gz |
better use of extra include files (both for tests and for old_ansi)
Diffstat (limited to 'ltests.h')
-rw-r--r-- | ltests.h | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -1,5 +1,5 @@ /* -** $Id: ltests.h,v 1.1 2001/02/02 15:12:25 roberto Exp roberto $ +** $Id: ltests.h,v 1.2 2001/02/05 19:08:01 roberto Exp roberto $ ** Internal Header for Debugging of the Lua Implementation ** See Copyright Notice in lua.h */ @@ -8,6 +8,8 @@ #define ltests_h +#include <stdlib.h> + #define LUA_DEBUG @@ -27,6 +29,14 @@ extern unsigned long memdebug_maxmem; extern unsigned long memdebug_memlimit; +#define l_malloc(s) debug_realloc(NULL, 0, s) +#define l_realloc(b, os, s) debug_realloc(b, os, s) +#define l_free(b, s) debug_realloc(b, s, 0) + +void *debug_realloc (void *block, size_t oldsize, size_t size); + + + /* test for lock/unlock */ #define LUA_USERSTATE int *lock; extern int islocked; |