pike.git / src / pike_types.cmod

version» Context lines:

pike.git/src/pike_types.cmod:748:    */   void debug_push_unlimited_array_type(enum PIKE_TYPE t)   {    struct compilation * c = MAYBE_THIS_COMPILATION;   #ifdef PIKE_DEBUG    if ((t != PIKE_T_ARRAY) && (t != PIKE_T_STRING)) {    Pike_fatal("Invalid type for push_array_type(): %s (%d)\n",    get_name_of_type(t), t);    }   #endif -  /* FIXME: Set car to unlimited length. */ +  push_int_type(0, MAX_INT32);    push_type(t);   }      static int (*program_id_to_id)(int) = NULL;      PMOD_EXPORT void set_program_id_to_id( int (*to)(int) )   {    program_id_to_id = to;   }   
pike.git/src/pike_types.cmod:901:    free_type(t2);    free_type(t1);    return;    }    /* FALLTHRU */    case T_FUNCTION:    case T_MANY:    case T_TUPLE:    case T_MAPPING:    case PIKE_T_RING: +  case T_ARRAY: +  case T_STRING:    /* Make a new type of the top two types. */    --Pike_compiler->type_stackp;    *Pike_compiler->type_stackp = mk_type(type,    *(Pike_compiler->type_stackp+1),    *Pike_compiler->type_stackp,    PT_COPY_BOTH);    break;       case T_PROGRAM:    if ((*Pike_compiler->type_stackp)->type != T_OBJECT) {
pike.git/src/pike_types.cmod:931:    case T_MULTISET:    case T_NOT:    case T_TYPE:    case PIKE_T_AUTO:    /* Make a new type of the top type, and put it in car. */    *Pike_compiler->type_stackp = mk_type(type,    *Pike_compiler->type_stackp, NULL,    PT_COPY_CAR);    break;    -  case T_ARRAY: -  case T_STRING: -  /* Make a new type of the top type, and put it in cdr. */ -  *Pike_compiler->type_stackp = mk_type(type, -  NULL, *Pike_compiler->type_stackp, -  PT_COPY_CDR); -  break; -  +     case T_SCOPE:    case T_ASSIGN:    case T_INT:    case T_OBJECT:    case PIKE_T_ATTRIBUTE:    case PIKE_T_NAME:    default:    /* Should not occur. */    Pike_fatal("Unsupported argument to push_type(): %d\n", type);    break;
pike.git/src/pike_types.cmod:1071:    /* fprintf(stderr, "push_reverse_type(%d)\n", type); */       switch(type) {    case T_FUNCTION:    case T_MANY:    case T_TUPLE:    case T_MAPPING:    case T_OR:    case T_AND:    case PIKE_T_RING: +  case PIKE_T_ARRAY: +  case PIKE_T_STRING:    {    /* Binary type-node. -- swap the types. */    struct pike_type *tmp = Pike_compiler->type_stackp[0];    Pike_compiler->type_stackp[0] = Pike_compiler->type_stackp[-1];    Pike_compiler->type_stackp[-1] = tmp;    break;    }    }    push_type(type);