pike.git / src / opcodes.c

version» Context lines:

pike.git/src/opcodes.c:15:   #include "opcodes.h"   #include "object.h"   #include "error.h"   #include "pike_types.h"   #include "pike_memory.h"   #include "fd_control.h"   #include "cyclic.h"   #include "builtin_functions.h"   #include "module_support.h"    - RCSID("$Id: opcodes.c,v 1.29 1998/07/04 16:56:14 grubba Exp $"); + RCSID("$Id: opcodes.c,v 1.30 1998/10/09 17:56:32 hubbe Exp $");      void index_no_free(struct svalue *to,struct svalue *what,struct svalue *ind)   {    INT32 i;    switch(what->type)    {    case T_ARRAY:    simple_array_index_no_free(to,what->u.array,ind);    break;   
pike.git/src/opcodes.c:50:       case T_STRING:    if(ind->type==T_INT)    {    i=ind->u.integer;    if(i<0)    i+=what->u.string->len;    if(i<0 || i>=what->u.string->len)    error("Index %d is out of range 0 - %d.\n", i, what->u.string->len-1);    else -  i=EXTRACT_UCHAR(what->u.string->str + i); +  i=index_shared_string(what->u.string,i);    to->type=T_INT;    to->subtype=NUMBER_NUMBER;    to->u.integer=i;    break;    }else{    error("Index is not an integer.\n");    }       case T_PROGRAM:    program_index_no_free(to, what->u.program, ind);