pike.git / src / mapping.c

version» Context lines:

pike.git/src/mapping.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: mapping.c,v 1.212 2008/07/16 15:47:08 grubba Exp $ + || $Id: mapping.c,v 1.213 2009/09/22 15:45:09 grubba Exp $   */      #include "global.h"   #include "main.h"   #include "object.h"   #include "mapping.h"   #include "svalue.h"   #include "array.h"   #include "pike_macros.h"   #include "pike_error.h"
pike.git/src/mapping.c:1998:    }       a = mapping_indices(m);    SET_ONERROR(err, do_free_array, a);       if(! m->data->size) { /* mapping_indices may remove elements */    my_strcat("([ ])");    }    else {    int save_t_flag = Pike_interpreter.trace_level; +  dynamic_buffer save_buf;       if (m->data->size == 1) {    my_strcat("([ /* 1 element */\n");    } else {    sprintf(buf, "([ /* %ld elements */\n", (long)m->data->size);    my_strcat(buf);    }    -  +  save_buffer (&save_buf);    Pike_interpreter.trace_level = 0;    if(SETJMP(catch)) {    free_svalue(&throw_value);    mark_free_svalue (&throw_value);    }    else    sort_array_destructively(a);    UNSETJMP(catch);    Pike_interpreter.trace_level = save_t_flag; -  +  restore_buffer (&save_buf);       for(e = 0; e < a->size; e++)    {    struct svalue *tmp;    if(e)    my_strcat(",\n");       for(d = 0; d < indent; d++)    my_putchar(' ');