pike.git / src / builtin.cmod

version» Context lines:

pike.git/src/builtin.cmod:2612:    {    INT_TYPE end = index;    INT32 numargs = 3;    INT32 i;       if (THIS->args)    numargs += THIS->args->size;       if (!end_or_none) {    if (index < 0) -  index_error("pike_frame->`[]", args, NULL, Pike_sp-args, +  index_error(args, NULL, Pike_sp-args,    "Indexing with negative index (%"PRINTPIKEINT"d)\n", index);    else if (index >= numargs) -  index_error("pike_frame->`[]", args, NULL, Pike_sp-args, +  index_error(args, NULL, Pike_sp-args,    "Indexing with too large index (%"PRINTPIKEINT"d)\n", index);    } else    end = end_or_none->u.integer;       pop_n_elems(args);       if (end_or_none) {    if ((end < 0) || (end < index) || (index >= numargs)) {    f_aggregate(0);    return;
pike.git/src/builtin.cmod:2678:    */    PIKEFUN mixed `[]=(int index, mixed value)    flags ID_PROTECTED;    {    INT32 numargs = 3;       if (THIS->args)    numargs += THIS->args->size;       if ((index < -numargs) || (index >= numargs)) -  index_error("pike_frame->`[]=", args, NULL, Pike_sp-args, +  index_error(args, NULL, Pike_sp-args,    "Index %"PRINTPIKEINT"d is out of array range 0..%d,\n",    index, numargs-1);    else if (index < 0)    index += numargs;       if (args > 2) {    pop_n_elems(args - 2);    args = 2;    }   
pike.git/src/builtin.cmod:3776:    struct array *ret;    TYPE_FIELD types;       for(e=0;e<args;e++)    {    if(TYPEOF(real_args[e]) == T_OBJECT &&    real_args[e].u.object->prog == automap_marker_program &&    OBJ2_AUTOMAP_MARKER(real_args[e].u.object)->depth >= d)    {    if(TYPEOF(tmpargs[e]) != T_ARRAY) -  index_error("__automap__", -  args, -  tmpargs, -  NULL, -  "Automap on non-array.\n"); +  index_error(args, tmpargs, NULL, "Automap on non-array.\n");    tmp=tmpargs[e].u.array->size;    if(tmp < size)    size=tmp;    }    }       if(size == 0x7fffffff)    Pike_error("No automap markers found in __automap__\n");       push_array(ret=allocate_array(size));