pike.git / src / pike_types.cmod

version» Context lines:

pike.git/src/pike_types.cmod:305:    * ZERO - -    * UNKNOWN - - Represented as NULL    * INT min (int) max (int)    * OBJECT implements/is object id(int)    * OPERATOR type Depends on bit #15. Added in 8.1    * TRANSITIVE fun_type fun_type Added in 8.1    *    * Operator types:    * FIND_LFUN object type lfun (int) Added in 8.1    * GET_RETURN fun type - Added in 8.1 +  * THRESHOLD type - Added in 8.1    * SET_CAR type type Added in 8.1    * SET_CDR type type Added in 8.1    * APPLY fun type arg type Added in 8.1    *    * Note that the cdr of a FUNCTION is a valid FUNCTION for the rest of    * the arguments.    *    * Note also that functions that don't take any arguments, or just    * a many argument just have a MANY node, and no FUNCTION node.    *
pike.git/src/pike_types.cmod:3024:    string_builder_sprintf(s, "transitive(%T, %T)", t->car, t->cdr);    break;       default:    {    if ((t->type & PIKE_T_MASK) == PIKE_T_OPERATOR) {    switch(t->type) {    case PIKE_T_GET_RETURN:    string_builder_strcat(s, "get_return");    break; +  case PIKE_T_THRESHOLD: +  string_builder_strcat(s, "threshold"); +  break;    case PIKE_T_SET_CAR:    string_builder_strcat(s, "set_car");    break;    case PIKE_T_SET_CDR:    string_builder_strcat(s, "set_cdr");    break;    default:    string_builder_sprintf(s, "operator(0x%04x)", t->type);    break;    }
pike.git/src/pike_types.cmod:4327:       case PIKE_T_OPERATOR:    push_remap_markers(t->car, remap, flags);       if (t->type & 0x8000) {    push_remap_markers(t->cdr, remap, flags);    push_reverse_type(t->type);    } else {    switch(t->type) {    case PIKE_T_GET_RETURN: +  case PIKE_T_THRESHOLD:    push_type_operator(t->type, NULL);    break;    case PIKE_T_FIND_LFUN:    push_type_operator(t->type, t->cdr);    break;    default:    Pike_fatal("Unsupported operator %d in push_remap_markers().\n",    t->type);    break;    }
pike.git/src/pike_types.cmod:14139:    struct pike_type *res = NULL;    switch(op) {    case PIKE_T_GET_RETURN:    {    struct call_state cs;    INIT_CALL_STATE(cs, NULL);    res = new_get_return_type(arg1, &cs, 0);    FREE_CALL_STATE(cs);    }    break; +  case PIKE_T_THRESHOLD: +  if (!arg1) break; +  copy_pike_type(res, any_type_string); +  break;    case PIKE_T_APPLY:    {    struct call_state cs;    INIT_CALL_STATE(cs, NULL);    res = low_new_check_call(arg1, arg2, 0, &cs, NULL);    FREE_CALL_STATE(cs);    }    break;    case PIKE_T_FIND_LFUN:    res = find_lfun_type(arg1, (ptrdiff_t)(void*)arg2);
pike.git/src/pike_types.cmod:14883:    Pike_fatal("compile_type_string(): Unknown lfun: \"%s\"\n", *cont);    }    *cont += str->len + 1;       push_type_operator(PIKE_T_FIND_LFUN,    (struct pike_type *)(ptrdiff_t)lfun);    break;    }       case PIKE_T_GET_RETURN: +  case PIKE_T_THRESHOLD:    low_make_pike_type(type_string + 2, cont);    push_type_operator(type, NULL);    break;       default:    Pike_fatal("compile_type_string(): Unknown operator: 0x%04x\n", type);    break;    }    }    break;