pike.git / src / builtin_functions.c

version» Context lines:

pike.git/src/builtin_functions.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: builtin_functions.c,v 1.454 2003/01/28 13:18:18 mast Exp $ + || $Id: builtin_functions.c,v 1.455 2003/02/01 15:37:22 mast Exp $   */      #include "global.h" - RCSID("$Id: builtin_functions.c,v 1.454 2003/01/28 13:18:18 mast Exp $"); + RCSID("$Id: builtin_functions.c,v 1.455 2003/02/01 15:37:22 mast Exp $");   #include "interpret.h"   #include "svalue.h"   #include "pike_macros.h"   #include "object.h"   #include "program.h"   #include "array.h"   #include "pike_error.h"   #include "constants.h"   #include "mapping.h"   #include "stralloc.h"
pike.git/src/builtin_functions.c:3844:       for(e=0;e<a->size;e++)    index_no_free(ITEM(a)+e, val, ITEM(tmp)+e);       Pike_sp--;    dmalloc_touch_svalue(Pike_sp);    pop_n_elems(args);    push_array(a);   }    -  - #ifdef PIKE_DEBUG +    /*! @decl void verify_internals()    *! @belongs Debug    *!    *! Perform sanity checks.    *!    *! This function goes through most of the internal Pike structures and    *! generates a fatal error if one of them is found to be out of order.    *! It is only used for debugging.    *!    *! @note -  *! This function is only available if the Pike runtime has been compiled -  *! with RTL debug. +  *! This function does a more thorough check if the Pike runtime has +  *! been compiled with RTL debug.    */   PMOD_EXPORT void f__verify_internals(INT32 args)   {    INT32 tmp=d_flag;    CHECK_SECURITY_OR_ERROR(SECURITY_BIT_SECURITY,    ("_verify_internals: permission denied.\n"));    d_flag=0x7fffffff; -  do_debug(); /* Runs gc too since d_flag > 3. */ + #ifdef PIKE_DEBUG +  do_debug(); /* Calls do_gc() since d_flag > 3. */ + #else +  do_gc(); + #endif    d_flag=tmp;    pop_n_elems(args);   }    -  + #ifdef PIKE_DEBUG +    /*! @decl int debug(int(0..) level)    *! @belongs Debug    *!    *! Set the run-time debug level.    *!    *! @returns    *! The old debug level will be returned.    *!    *! @note    *! This function is only available if the Pike runtime has been compiled
pike.git/src/builtin_functions.c:7944:   #endif      #ifdef HAVE_MKTIME      /* function(int,int,int,int,int,int,int,void|int:int)|function(object|mapping:int) */    ADD_EFUN("mktime",f_mktime,    tOr(tFunc(tInt tInt tInt tInt tInt tInt tInt tOr(tVoid,tInt),tInt),    tFunc(tOr(tObj,tMapping),tInt)),OPT_TRY_OPTIMIZE);   #endif    - #ifdef PIKE_DEBUG -  +    /* function(:void) */    ADD_EFUN("_verify_internals",f__verify_internals,    tFunc(tNone,tVoid),OPT_SIDE_EFFECT|OPT_EXTERNAL_DEPEND);    -  + #ifdef PIKE_DEBUG +    /* function(int:int) */    ADD_EFUN("_debug",f__debug,    tFunc(tInt,tInt),OPT_SIDE_EFFECT|OPT_EXTERNAL_DEPEND);      /* function(int:int) */    ADD_EFUN("_optimizer_debug",f__optimizer_debug,    tFunc(tInt,tInt),OPT_SIDE_EFFECT|OPT_EXTERNAL_DEPEND);      /* function(int:int) */    ADD_EFUN("_assembler_debug",f__assembler_debug,