pike.git / src / builtin.cmod

version» Context lines:

pike.git/src/builtin.cmod:60:   #define SET_GMTOFF(TM, VAL) (((TM)->tm_gmtoff) = (VAL))   #define SET_ZONE(this, VAL) ((this)->t.tm_zone = (VAL))   #else    struct tm_extra { const char *tm_zone; };   #define GET_GMTOFF(TM) 0   #define GET_ZONE(this) ((this)->extra.tm_zone)   #define SET_GMTOFF(TM, VAL) (VAL)   #define SET_ZONE(this, VAL) ((this)->extra.tm_zone = (VAL))   #endif    + static void gc_check_frame(struct pike_frame *f) + { +  if(f->flags & PIKE_FRAME_MALLOCED_LOCALS) +  { +  if(f->current_object) +  debug_gc_check (f->current_object, " as current_object in a frame"); +  if(f->current_program) +  debug_gc_check (f->current_program, " as current_program in a frame"); +  debug_gc_check_svalues (f->locals, f->num_locals, " in locals of a frame"); +  if(f->scope && !debug_gc_check (f->scope, " as scope frame of a frame")) +  gc_check_frame(f->scope); +  } + } +  + static void gc_recurse_frame(struct pike_frame *f) + { +  if(f->current_object) +  gc_recurse_object(f->current_object); +  if(f->current_program) +  gc_recurse_program(f->current_program); +  if(f->flags & PIKE_FRAME_MALLOCED_LOCALS) +  gc_recurse_svalues(f->locals,f->num_locals); +  if(f->scope) +  gc_recurse_frame(f->scope); + } +    DECLARATIONS      /*! @module System    */      /*! @class TM    *! A wrapper for the system struct tm time keeping structure.    *! This can be used as a (very) lightweight alternative to Calendar.    */   PIKECLASS TM
pike.git/src/builtin.cmod:5968:       EXIT    {    if(THIS->trampoline.frame)    {    free_pike_scope(THIS->trampoline.frame);    THIS->trampoline.frame=0;    }    }    -  static void gc_check_frame(struct pike_frame *f) -  { -  if(f->flags & PIKE_FRAME_MALLOCED_LOCALS) -  { -  if(f->current_object) -  debug_gc_check (f->current_object, " as current_object in trampoline frame"); -  if(f->current_program) -  debug_gc_check (f->current_program, " as current_program in trampoline frame"); -  debug_gc_check_svalues (f->locals, f->num_locals, " in locals of trampoline frame"); -  if(f->scope && !debug_gc_check (f->scope, " as scope frame of trampoline frame")) -  gc_check_frame(f->scope); -  } -  } -  +     GC_CHECK    {    if (THIS->trampoline.frame &&    !debug_gc_check(THIS->trampoline.frame, " as trampoline frame"))    gc_check_frame(THIS->trampoline.frame);    }    -  static void gc_recurse_frame(struct pike_frame *f) -  { -  if(f->current_object) gc_recurse_object(f->current_object); -  if(f->current_program) gc_recurse_program(f->current_program); -  if(f->flags & PIKE_FRAME_MALLOCED_LOCALS) -  gc_recurse_svalues(f->locals,f->num_locals); -  if(f->scope) gc_recurse_frame(f->scope); -  } -  +     GC_RECURSE    {    if (THIS->trampoline.frame) gc_recurse_frame(THIS->trampoline.frame);    }       PIKEFUN void `()(mixed ... ignored)    {    Pike_error("Internal error: Trampoline magic failed!\n");    }