pike.git / src / builtin.cmod

version» Context lines:

pike.git/src/builtin.cmod:1:   /* -*- c -*-   || 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.cmod,v 1.225 2008/10/04 18:31:12 mast Exp $ + || $Id: builtin.cmod,v 1.226 2008/11/02 19:57:58 grubba Exp $   */      #include "global.h"   #include "interpret.h"   #include "svalue.h"   #include "pike_macros.h"   #include "object.h"   #include "program.h"   #include "array.h"   #include "pike_error.h"
pike.git/src/builtin.cmod:1012:    case PIKE_T_FUNCTION:    if(func->subtype == FUNCTION_BUILTIN) break;    if(!func->u.object->prog)    bad_arg_error("function_name", Pike_sp-args, args, 1,    "function", Pike_sp-args,    "Destructed object.\n");    if(func->u.object->prog == pike_trampoline_program)    {    struct pike_trampoline *t;    t=((struct pike_trampoline *)func->u.object->storage); +  +  /* FIXME: Adjust lambda names. */ +     if(t->frame->current_object->prog)    REF_RETURN ID_FROM_INT(t->frame->current_object->prog,    t->func)->name;    }    -  +  /* FIXME: Adjust lambda names. */ +     REF_RETURN ID_FROM_INT(func->u.object->prog, func->subtype)->name;    }    pop_n_elems(args);    push_int(0);   }      /*! @decl object function_object(function f)    *!    *! Return the object the function @[f] is in.    *!
pike.git/src/builtin.cmod:3974:      void init_builtin(void)   {    init_pike_list_node_blocks();    INIT   }      void exit_builtin(void)   {    EXIT + #ifndef DO_PIKE_CLEANUP +  /* This is performed by exit_builtin_modules() at a later point +  * in this case, so that the pike_list_node's are valid at cleanup +  * time, thus avoiding "got invalid pointer" fatals at exit. +  */    free_all_pike_list_node_blocks(); -  + #endif   #ifndef USE_SETENV    if (env_allocs) free_mapping (env_allocs);   #endif   }