pike.git / src / operators.c

version» Context lines:

pike.git/src/operators.c:39:       /* This calculation should always give some margin based on the size. */    /* It utilizes that log10(256) ~= 2.4 < 5/2. */    /* One extra char for the sign and one for the \0 terminator. */   #define MAX_INT_SPRINTF_LEN (2 + (SIZEOF_INT_TYPE * 5 + 1) / 2)       /* Enough to hold a Pike float or int in textform    */   #define MAX_NUM_BUF (MAXIMUM(MAX_INT_SPRINTF_LEN,MAX_FLOAT_SPRINTF_LEN))    - static int has_lfun( enum LFUN lfun, int arg ); + static int has_lfun(enum LFUN lfun, int arg);   static int call_lfun(enum LFUN left, enum LFUN right); - static int call_lhs_lfun( enum LFUN lfun, int arg ); + static int call_lhs_lfun(enum LFUN lfun, int arg);      void index_no_free(struct svalue *to,struct svalue *what,struct svalue *ind)   {    switch(TYPEOF(*what))    {    case T_ARRAY:    simple_array_index_no_free(to,what->u.array,ind);    break;       case T_MAPPING:
pike.git/src/operators.c:1334:    {    if(TYPEOF(sp[-2]) == PIKE_T_OBJECT &&    /* Note: pairwise add always has an extra reference! */    sp[-2].u.object->refs == 2 &&    call_lhs_lfun(LFUN_ADD_EQ,2))    return 1; /* optimized version of +. */    if(call_lfun(LFUN_ADD, LFUN_RADD))    return 1; /* standard editon */    }    -  +     if (TYPEOF(sp[-2]) != TYPEOF(sp[-1]))    {    if(IS_UNDEFINED(sp-2))    {    stack_swap();    pop_stack();    return 1;    }       if(IS_UNDEFINED(sp-1))