pike.git / src / interpret_functions.h

version» Context lines:

pike.git/src/interpret_functions.h: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: interpret_functions.h,v 1.143 2003/03/25 15:40:42 marcus Exp $ + || $Id: interpret_functions.h,v 1.144 2003/04/03 14:56:26 grubba Exp $   */      /*    * Opcode definitions for the interpreter.    */      #include "global.h"      #undef CJUMP   #undef AUTO_BIGNUM_LOOP_TEST
pike.git/src/interpret_functions.h:1714:      OPCODE1(F_SIZEOF_LOCAL, "sizeof local", 0, {    push_int(pike_sizeof(Pike_fp->locals+arg1));   });      OPCODE1_ALIAS(F_SSCANF, "sscanf", 0, o_sscanf);      #define MKAPPLY(OP,OPCODE,NAME,TYPE, ARG2, ARG3) \   OP(PIKE_CONCAT(F_,OPCODE),NAME, I_PC_AT_NEXT, { \   Pike_fp->pc=PROG_COUNTER; \ - if(low_mega_apply(TYPE,0,DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \ + if(low_mega_apply(TYPE,DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \    ARG2, ARG3)) \   { \    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL; \    DO_JUMP_TO(Pike_fp->pc); \   } \   }); \    \   OP(PIKE_CONCAT3(F_,OPCODE,_AND_POP),NAME " & pop", I_PC_AT_NEXT, { \    Pike_fp->pc=PROG_COUNTER; \ -  if(low_mega_apply(TYPE, 0, DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \ +  if(low_mega_apply(TYPE, DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \    ARG2, ARG3)) \    { \    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL | PIKE_FRAME_RETURN_POP; \    DO_JUMP_TO(Pike_fp->pc); \    }else{ \    pop_stack(); \    } \   }); \    \   PIKE_CONCAT(OP,_RETURN)(PIKE_CONCAT3(F_,OPCODE,_AND_RETURN), \    NAME " & return", 0, { \ -  if(low_mega_apply(TYPE,0,DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \ +  if(low_mega_apply(TYPE,DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp)), \    ARG2,ARG3)) \    { \    PIKE_OPCODE_T *addr = Pike_fp->pc; \    DO_IF_DEBUG(Pike_fp->next->pc=0); \    unlink_previous_frame(); \    DO_JUMP_TO(addr); \    }else{ \    DO_DUMB_RETURN; \    } \   }); \         #define MKAPPLY2(OP,OPCODE,NAME,TYPE, ARG2, ARG3) \    \   MKAPPLY(OP,OPCODE,NAME,TYPE, ARG2, ARG3) \    \   OP(PIKE_CONCAT(F_MARK_,OPCODE),"mark, " NAME, I_PC_AT_NEXT, { \    Pike_fp->pc=PROG_COUNTER; \ -  if(low_mega_apply(TYPE,0, 0, \ +  if(low_mega_apply(TYPE, 0, \    ARG2, ARG3)) \    { \    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL; \    DO_JUMP_TO(Pike_fp->pc); \    } \   }); \    \   OP(PIKE_CONCAT3(F_MARK_,OPCODE,_AND_POP),"mark, " NAME " & pop", I_PC_AT_NEXT, { \    Pike_fp->pc=PROG_COUNTER; \ -  if(low_mega_apply(TYPE, 0, 0, \ +  if(low_mega_apply(TYPE, 0, \    ARG2, ARG3)) \    { \    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL | PIKE_FRAME_RETURN_POP; \    DO_JUMP_TO(Pike_fp->pc); \    }else{ \    pop_stack(); \    } \   }); \    \   PIKE_CONCAT(OP,_RETURN)(PIKE_CONCAT3(F_MARK_,OPCODE,_AND_RETURN), \    "mark, " NAME " & return", 0, { \ -  if(low_mega_apply(TYPE,0, 0, \ +  if(low_mega_apply(TYPE, 0, \    ARG2,ARG3)) \    { \    PIKE_OPCODE_T *addr = Pike_fp->pc; \    DO_IF_DEBUG(Pike_fp->next->pc=0); \    unlink_previous_frame(); \    DO_JUMP_TO(addr); \    }else{ \    DO_DUMB_RETURN; \    } \   })
pike.git/src/interpret_functions.h:1816:    struct program *p;    if((p=o->prog))    {    if(FIND_LFUN(p, LFUN_ARROW) == -1)    {    int fun;    fun=find_shared_string_identifier(Pike_fp->context.prog->strings[arg1],    p);    if(fun >= 0)    { -  if(low_mega_apply(APPLY_LOW, 0, args-1, o, (void *)(ptrdiff_t)fun)) +  if(low_mega_apply(APPLY_LOW, args-1, o, (void *)(ptrdiff_t)fun))    {    Pike_fp->save_sp--;    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL;    DO_JUMP_TO(Pike_fp->pc);    }    stack_unlink(1);    DONE;    }    }    }
pike.git/src/interpret_functions.h:1842:       tmp.type=PIKE_T_STRING;    tmp.u.string=Pike_fp->context.prog->strings[arg1];    tmp.subtype=1;       index_no_free(&tmp2, s, &tmp);    free_svalue(s);    *s=tmp2;    print_return_value();    -  if(low_mega_apply(APPLY_STACK, 0, args, 0, 0)) +  if(low_mega_apply(APPLY_STACK, args, 0, 0))    {    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL;    DO_JUMP_TO(Pike_fp->pc);    }    DONE;    }   });      OPCODE1(F_CALL_OTHER_AND_POP,"call other & pop", I_PC_AT_NEXT, {    INT32 args=DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp));
pike.git/src/interpret_functions.h:1868:    struct program *p;    if((p=o->prog))    {    if(FIND_LFUN(p, LFUN_ARROW) == -1)    {    int fun;    fun=find_shared_string_identifier(Pike_fp->context.prog->strings[arg1],    p);    if(fun >= 0)    { -  if(low_mega_apply(APPLY_LOW, 0, args-1, o, (void *)(ptrdiff_t)fun)) +  if(low_mega_apply(APPLY_LOW, args-1, o, (void *)(ptrdiff_t)fun))    {    Pike_fp->save_sp--;    Pike_fp->flags |=    PIKE_FRAME_RETURN_INTERNAL |    PIKE_FRAME_RETURN_POP;    DO_JUMP_TO(Pike_fp->pc);    }    pop_2_elems();    DONE;    }
pike.git/src/interpret_functions.h:1896:       tmp.type=PIKE_T_STRING;    tmp.u.string=Pike_fp->context.prog->strings[arg1];    tmp.subtype=1;       index_no_free(&tmp2, s, &tmp);    free_svalue(s);    *s=tmp2;    print_return_value();    -  if(low_mega_apply(APPLY_STACK, 0, args, 0, 0)) +  if(low_mega_apply(APPLY_STACK, args, 0, 0))    {    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL | PIKE_FRAME_RETURN_POP;    DO_JUMP_TO(Pike_fp->pc);    }    pop_stack();    }   });      OPCODE1(F_CALL_OTHER_AND_RETURN,"call other & return", 0, {    INT32 args=DO_NOT_WARN((INT32)(Pike_sp - *--Pike_mark_sp));
pike.git/src/interpret_functions.h:1921:    struct program *p;    if((p=o->prog))    {    if(FIND_LFUN(p, LFUN_ARROW) == -1)    {    int fun;    fun=find_shared_string_identifier(Pike_fp->context.prog->strings[arg1],    p);    if(fun >= 0)    { -  if(low_mega_apply(APPLY_LOW, 0, args-1, o, (void *)(ptrdiff_t)fun)) +  if(low_mega_apply(APPLY_LOW, args-1, o, (void *)(ptrdiff_t)fun))    {    PIKE_OPCODE_T *addr = Pike_fp->pc;    Pike_fp->save_sp--;    DO_IF_DEBUG(Pike_fp->next->pc=0);    unlink_previous_frame();    DO_JUMP_TO(addr);    }    stack_unlink(1);    DO_DUMB_RETURN;    }
pike.git/src/interpret_functions.h:1949:       tmp.type=PIKE_T_STRING;    tmp.u.string=Pike_fp->context.prog->strings[arg1];    tmp.subtype=1;       index_no_free(&tmp2, s, &tmp);    free_svalue(s);    *s=tmp2;    print_return_value();    -  if(low_mega_apply(APPLY_STACK, 0, args, 0, 0)) +  if(low_mega_apply(APPLY_STACK, args, 0, 0))    {    PIKE_OPCODE_T *addr = Pike_fp->pc;    DO_IF_DEBUG(Pike_fp->next->pc=0);    unlink_previous_frame();    DO_JUMP_TO(addr);    }    DO_DUMB_RETURN;    }   });   
pike.git/src/interpret_functions.h:2130:    (p->inherits[p->identifier_references[Pike_fp->context.identifier_level +    arg1].inherit_offset].prog !=    Pike_fp->context.prog)) ||    (ID_FROM_INT(p, arg1+Pike_fp->context.identifier_level)->    identifier_flags & IDENTIFIER_SCOPE_USED))    {    PIKE_OPCODE_T *faddr = PROG_COUNTER+GET_JUMP();    ptrdiff_t num_locals = READ_INCR_BYTE(faddr); /* ignored */    ptrdiff_t args = READ_INCR_BYTE(faddr);    -  if(low_mega_apply(APPLY_LOW, 0, +  if(low_mega_apply(APPLY_LOW,    args,    Pike_fp->current_object,    (void *)(ptrdiff_t)(arg1+    Pike_fp->context.identifier_level)))    {    Pike_fp->flags |= PIKE_FRAME_RETURN_INTERNAL;    addr = Pike_fp->pc;    }    DO_JUMP_TO(addr);    }