pike.git / src / constants.c

version» Context lines:

pike.git/src/constants.c:8:   #include "pike_macros.h"   #include "program.h"   #include "pike_types.h"   #include "stralloc.h"   #include "pike_memory.h"   #include "interpret.h"   #include "mapping.h"   #include "error.h"   #include "block_alloc.h"    - RCSID("$Id: constants.c,v 1.15 1999/03/02 03:13:13 hubbe Exp $"); + RCSID("$Id: constants.c,v 1.16 1999/04/08 23:54:26 hubbe Exp $");      static INT32 num_callable=0;   static struct mapping *builtin_constants = 0;      struct mapping *get_builtin_constants(void)   {    if(!builtin_constants)    builtin_constants=allocate_mapping(20);       return builtin_constants;
pike.git/src/constants.c:146:    s.subtype=FUNCTION_BUILTIN;    add_ref(n);    s.u.efun=low_make_callable(fun, n, t, flags, optimize, docode);    low_add_efun(n, &s);    free_svalue(&s);    free_string(n);   }      void cleanup_added_efuns(void)   { + #ifdef DO_PIKE_CLEANUP    if(builtin_constants)    {    free_mapping(builtin_constants);    builtin_constants=0;    } -  free_all_callable_blocks(); + #endif   }   void count_memory_in_callables(INT32 *num_, INT32 *size_)   {    *num_=num_callable;    *size_=num_callable*sizeof(struct callable);   }