pike.git / src / mapping.c

version» Context lines:

pike.git/src/mapping.c:1:   /*\   ||| This file a part of Pike, and is copyright by Fredrik Hubinette   ||| Pike is distributed as GPL (General Public License)   ||| See the files COPYING and DISCLAIMER for more information.   \*/   /**/   #include "global.h" - RCSID("$Id: mapping.c,v 1.120 2001/04/14 11:22:33 jhs Exp $"); + RCSID("$Id: mapping.c,v 1.121 2001/04/15 16:13:18 mast Exp $");   #include "main.h"   #include "object.h"   #include "mapping.h"   #include "svalue.h"   #include "array.h"   #include "pike_macros.h"   #include "pike_error.h"   #include "pike_memory.h"   #include "dynamic_buffer.h"   #include "interpret.h"
pike.git/src/mapping.c:98: Inside #if defined(PIKE_DEBUG)
   }       if(val_types & ~(m->data->val_types))    fatal("Mapping value types out of order!\n");       if(ind_types & ~(m->data->ind_types))    fatal("Mapping indices types out of order!\n");   }   #endif    - static struct mapping_data empty_data = { 1, 1, 0,0,0,0,0,0 }; - static struct mapping_data weak_empty_data = { 1, 1, 0,0,0,0,0,0,1 }; + static struct mapping_data empty_data = +  { PIKE_CONSTANT_MEMOBJ_INIT(1), 1, 0,0,0,0,0,0,0 }; + static struct mapping_data weak_empty_data = +  { PIKE_CONSTANT_MEMOBJ_INIT(1), 1, 0,0,0,0,0,0,1 };      /* This function allocates the hash table and svalue space for a mapping    * struct. The size is the max number of indices that can fit in the    * allocated space.    */   static void init_mapping(struct mapping *m,    INT32 size,    INT16 flags)   {    struct mapping_data *md;