pike.git / src / encode.c

version» Context lines:

pike.git/src/encode.c:445:    } else {    addchar(T_ARRAY ^ MIN_REF_TYPE);    EDB(1, {    ENCODE_WERR(".type %s",    get_name_of_type(t->type));    });    }    t = t->cdr;    goto one_more_type;    } else if (t->type <= MAX_TYPE) { +  if (t->type == T_FUNCTION) { +  struct pike_type *tmp = t; +  while (tmp->type == T_FUNCTION) tmp = tmp->cdr; +  if (tmp->type != T_MANY) { +  /* Function type needing tFuncArg. */ +  while (t->type == T_FUNCTION) { +  addchar(t->type); /* Intentional !!!!! */ +  EDB(1, { +  ENCODE_WERR(".type function_arg"); +  }); +  encode_type(t->car, data); +  t = t->cdr; +  } +  goto one_more_type; +  } +  }    addchar(t->type ^ MIN_REF_TYPE);    EDB(1, {    ENCODE_WERR(".type %s",    get_name_of_type(t->type));    });    } else {    addchar(t->type);    EDB(1, {    ENCODE_WERR(".type %s",    get_name_of_type(t->type));
pike.git/src/encode.c:2724:    low_decode_type(data);    push_assign_type(tmp); /* Actually reverse, but they're the same */    break;       case T_SCOPE:    tmp = GETC();    low_decode_type(data);    push_scope_type(tmp); /* Actually reverse, but they're the same */    break;    +  case PIKE_T_FUNCTION_ARG: +  low_decode_type(data); /* Argument */ +  low_decode_type(data); /* Continuation */ +  push_reverse_type(T_FUNCTION); +  break; +     case T_FUNCTION:    {    int narg = 0;       while (GETC() != T_MANY) {    data->ptr--;    low_decode_type(data);    narg++;    }    low_decode_type(data); /* Many */