pike.git / src / interpret_functions.h

version» Context lines:

pike.git/src/interpret_functions.h:1:   /* -  * $Id: interpret_functions.h,v 1.33 2000/12/01 03:19:00 hubbe Exp $ +  * $Id: interpret_functions.h,v 1.34 2000/12/01 08:09:48 hubbe Exp $    *    * Opcode definitions for the interpreter.    */      OPCODE0(F_UNDEFINED,"push UNDEFINED")    push_int(0);    Pike_sp[-1].subtype=NUMBER_UNDEFINED;   BREAK;      OPCODE0(F_CONST0, "push 0")
pike.git/src/interpret_functions.h:99:    Pike_sp++;    print_return_value();   BREAK;      OPCODE2(F_EXTERNAL,"external")   {    struct external_variable_context loc;       loc.o=Pike_fp->current_object;    if(!loc.o->prog) -  error("Cannot access parent of destructed object.\n"); +  Pike_error("Cannot access parent of destructed object.\n");       loc.parent_identifier=Pike_fp->fun;    loc.inherit=INHERIT_FROM_INT(loc.o->prog, Pike_fp->fun);       find_external_context(&loc, arg2);      #ifdef PIKE_DEBUG    TRACE((5,"- Identifier=%d Offset=%d\n",    arg1,    loc.inherit->identifier_level));
pike.git/src/interpret_functions.h:126:    print_return_value();   }   BREAK;      OPCODE2(F_EXTERNAL_LVALUE,"& external")   {    struct external_variable_context loc;       loc.o=Pike_fp->current_object;    if(!loc.o->prog) -  error("Cannot access parent of destructed object.\n"); +  Pike_error("Cannot access parent of destructed object.\n");       loc.parent_identifier=Pike_fp->fun;    loc.inherit=INHERIT_FROM_INT(loc.o->prog, Pike_fp->fun);       find_external_context(&loc, arg2);      #ifdef PIKE_DEBUG    TRACE((5,"- Identifier=%d Offset=%d\n",    arg1,    loc.inherit->identifier_level));
pike.git/src/interpret_functions.h:175:   OPCODE2(F_LOCAL_2_LOCAL, "local = local")    assign_svalue(Pike_fp->locals + arg1, Pike_fp->locals + arg2);   BREAK;      OPCODE2(F_LOCAL_2_GLOBAL, "global = local")   {    INT32 tmp = arg1 + Pike_fp->context.identifier_level;    struct identifier *i;       if(!Pike_fp->current_object->prog) -  error("Cannot access global variables in destructed object.\n"); +  Pike_error("Cannot access global variables in destructed object.\n");       i = ID_FROM_INT(Pike_fp->current_object->prog, tmp);    if(!IDENTIFIER_IS_VARIABLE(i->identifier_flags)) -  error("Cannot assign functions or constants.\n"); +  Pike_error("Cannot assign functions or constants.\n");    if(i->run_time_type == PIKE_T_MIXED)    {    assign_svalue((struct svalue *)GLOBAL_FROM_INT(tmp),    Pike_fp->locals + arg2);    }else{    assign_to_short_svalue((union anything *)GLOBAL_FROM_INT(tmp),    i->run_time_type,    Pike_fp->locals + arg2);    }   }
pike.git/src/interpret_functions.h:215:    Pike_sp[1].type = T_VOID;    Pike_sp += 2;   BREAK;      OPCODE2(F_LEXICAL_LOCAL,"lexical local")   {    struct pike_frame *f=Pike_fp;    while(arg2--)    {    f=f->scope; -  if(!f) error("Lexical scope error.\n"); +  if(!f) Pike_error("Lexical scope Pike_error.\n");    }    push_svalue(f->locals + arg1);    print_return_value();   }   BREAK;      OPCODE2(F_LEXICAL_LOCAL_LVALUE,"&lexical local")   {    struct pike_frame *f=Pike_fp;    while(arg2--)    {    f=f->scope; -  if(!f) error("Lexical scope error.\n"); +  if(!f) Pike_error("Lexical scope Pike_error.\n");    }    Pike_sp[0].type=T_LVALUE;    Pike_sp[0].u.lval=f->locals+arg1;    Pike_sp[1].type=T_VOID;    Pike_sp+=2;   }   BREAK;      OPCODE1(F_ARRAY_LVALUE, "[ lvalues ]")    f_aggregate(arg1*2);
pike.git/src/interpret_functions.h:442:    f_add(2);    assign_lvalue(Pike_sp-3,Pike_sp-1);    pop_n_elems(3);   BREAK;      OPCODE1(F_GLOBAL_LVALUE, "& global")   {    struct identifier *i;    INT32 tmp=arg1 + Pike_fp->context.identifier_level;    if(!Pike_fp->current_object->prog) -  error("Cannot access global variables in destructed object.\n"); +  Pike_error("Cannot access global variables in destructed object.\n");    i=ID_FROM_INT(Pike_fp->current_object->prog, tmp);       if(!IDENTIFIER_IS_VARIABLE(i->identifier_flags)) -  error("Cannot re-assign functions or constants.\n"); +  Pike_error("Cannot re-assign functions or constants.\n");       if(i->run_time_type == PIKE_T_MIXED)    {    Pike_sp[0].type=T_LVALUE;    Pike_sp[0].u.lval=(struct svalue *)GLOBAL_FROM_INT(tmp);    }else{    Pike_sp[0].type=T_SHORT_LVALUE;    Pike_sp[0].u.short_lval= (union anything *)GLOBAL_FROM_INT(tmp);    Pike_sp[0].subtype=i->run_time_type;    }
pike.git/src/interpret_functions.h:640:    free_svalue(Pike_fp->locals + arg1);    Pike_fp->locals[arg1] = Pike_sp[-1];    Pike_sp--;   BREAK;      OPCODE1(F_ASSIGN_GLOBAL, "assign global")   {    struct identifier *i;    INT32 tmp=arg1 + Pike_fp->context.identifier_level;    if(!Pike_fp->current_object->prog) -  error("Cannot access global variables in destructed object.\n"); +  Pike_error("Cannot access global variables in destructed object.\n");       i=ID_FROM_INT(Pike_fp->current_object->prog, tmp);    if(!IDENTIFIER_IS_VARIABLE(i->identifier_flags)) -  error("Cannot assign functions or constants.\n"); +  Pike_error("Cannot assign functions or constants.\n");    if(i->run_time_type == PIKE_T_MIXED)    {    assign_svalue((struct svalue *)GLOBAL_FROM_INT(tmp), Pike_sp-1);    }else{    assign_to_short_svalue((union anything *)GLOBAL_FROM_INT(tmp),    i->run_time_type,    Pike_sp-1);    }   }   BREAK;      OPCODE1(F_ASSIGN_GLOBAL_AND_POP, "assign global and pop")   {    struct identifier *i;    INT32 tmp=arg1 + Pike_fp->context.identifier_level;    if(!Pike_fp->current_object->prog) -  error("Cannot access global variables in destructed object.\n"); +  Pike_error("Cannot access global variables in destructed object.\n");       i=ID_FROM_INT(Pike_fp->current_object->prog, tmp);    if(!IDENTIFIER_IS_VARIABLE(i->identifier_flags)) -  error("Cannot assign functions or constants.\n"); +  Pike_error("Cannot assign functions or constants.\n");       if(i->run_time_type == PIKE_T_MIXED)    {    struct svalue *s=(struct svalue *)GLOBAL_FROM_INT(tmp);    free_svalue(s);    Pike_sp--;    *s=*Pike_sp;    }else{    assign_to_short_svalue((union anything *)GLOBAL_FROM_INT(tmp),    i->run_time_type,
pike.git/src/interpret_functions.h:1173:    default:    PIKE_ERROR("@", "Bad argument.\n", Pike_sp, 1);       case PIKE_T_OBJECT:    if(!Pike_sp[-1].u.object->prog ||    FIND_LFUN(Pike_sp[-1].u.object->prog,LFUN__VALUES) == -1)    PIKE_ERROR("@", "Bad argument.\n", Pike_sp, 1);       apply_lfun(Pike_sp[-1].u.object, LFUN__VALUES, 0);    if(Pike_sp[-1].type != PIKE_T_ARRAY) -  error("Bad return type from o->_values() in @\n"); +  Pike_error("Bad return type from o->_values() in @\n");    free_svalue(Pike_sp-2);    Pike_sp[-2]=Pike_sp[-1];    Pike_sp--;    break;       case PIKE_T_ARRAY: break;    }    Pike_sp--;    push_array_items(Pike_sp->u.array);   BREAK;