pike.git / src / pike_types.cmod

version» Context lines:

pike.git/src/pike_types.cmod:41:      #ifdef PIKE_TYPE_DEBUG   static int indent=0;   #endif      int max_correct_args;      PMOD_EXPORT struct pike_type *string0_type_string;   PMOD_EXPORT struct pike_type *string_type_string;   PMOD_EXPORT struct pike_type *int_type_string; + PMOD_EXPORT struct pike_type *int0_type_string;   PMOD_EXPORT struct pike_type *int_pos_type_string;   PMOD_EXPORT struct pike_type *float_type_string;   PMOD_EXPORT struct pike_type *function_type_string;   PMOD_EXPORT struct pike_type *void_function_type_string;   PMOD_EXPORT struct pike_type *object_type_string;   PMOD_EXPORT struct pike_type *program_type_string;   PMOD_EXPORT struct pike_type *array_type_string;   PMOD_EXPORT struct pike_type *multiset_type_string;   PMOD_EXPORT struct pike_type *mapping_type_string;   PMOD_EXPORT struct pike_type *type_type_string;
pike.git/src/pike_types.cmod:4759:       case TWOT(T_ZERO, T_VOID):    if (op & PT_BINOP_AND) {    /* Return zero. */    add_ref(a);    return a;    }    return NULL;       case TWOT(T_ZERO, T_INT): -  if ((CAR_TO_INT(b) <= 0) && (CDR_TO_INT(b) >= 0)) { -  if (op == PT_BINOP_AND) { -  add_ref(a); -  return a; -  } else if (op == PT_BINOP_MINUS) { -  return NULL; -  } -  } -  if (op == PT_BINOP_AND) { -  return NULL; -  } else if (op == PT_BINOP_MINUS) { -  add_ref(a); -  return a; -  } +  a = int0_type_string;    break;       case TWOT(T_INT, T_ZERO): -  if ((CAR_TO_INT(a) <= 0) && (CDR_TO_INT(a) >= 0)) { -  if (op == PT_BINOP_AND) { -  add_ref(b); -  return b; -  } else if (op == PT_BINOP_MINUS) { -  return NULL; -  } -  } -  if (op == PT_BINOP_AND) { -  return NULL; -  } else if (op == PT_BINOP_MINUS) { -  type_stack_mark(); -  if (CAR_TO_INT(a) < 0) { -  push_int_type(CAR_TO_INT(a), -1); -  } -  if (CDR_TO_INT(a) > 0) { -  push_int_type(1, CDR_TO_INT(a)); -  if (CAR_TO_INT(a) < 0) { -  push_reverse_type(T_OR); -  } -  } -  return pop_unfinished_type(); -  } +  b = int0_type_string;    break;       /* T_TYPE and T_PROGRAM are essentially the same thing. */    case TWOT(T_TYPE, T_TYPE):    case TWOT(T_TYPE, T_PROGRAM):    case TWOT(T_PROGRAM, T_TYPE):    case TWOT(T_PROGRAM, T_PROGRAM):    tmp = low_type_binop(op, a->car, b->car, remap,    aflags, bflags, remap_flags);    if (!tmp) return NULL;
pike.git/src/pike_types.cmod:12941:    type_stack = xalloc(sizeof(struct pike_type *)*PIKE_TYPE_STACK_SIZE);    if( !pike_type_mark_stack )    pike_type_mark_stack = xalloc(sizeof(struct pike_type *)*PIKE_TYPE_STACK_SIZE / 4);       Pike_compiler->type_stackp = type_stack;    Pike_compiler->pike_type_mark_stackp = pike_type_mark_stack;       type_stack_mark(); /* Type stack marker sentinel. */       int_type_string = CONSTTYPE(tInt); /* MUST come before string and array! */ +  int0_type_string = CONSTTYPE(tInt0);    int_pos_type_string = CONSTTYPE(tIntPos);    string0_type_string = CONSTTYPE(tStr0);    string_type_string = CONSTTYPE(tStr32);    object_type_string = CONSTTYPE(tObj);    program_type_string = CONSTTYPE(tPrg(tObj));    float_type_string = CONSTTYPE(tFloat);    mixed_type_string = CONSTTYPE(tMix);    array_type_string = CONSTTYPE(tArray);    multiset_type_string = CONSTTYPE(tMultiset);    mapping_type_string = CONSTTYPE(tMapping);
pike.git/src/pike_types.cmod:13025:   #endif /* DO_PIKE_CLEANUP */       clear_markers();       free_type(string0_type_string);    string0_type_string = NULL;    free_type(string_type_string);    string_type_string = NULL;    free_type(int_type_string);    int_type_string = NULL; +  free_type(int0_type_string); +  int0_type_string = NULL;    free_type(int_pos_type_string);    int_pos_type_string = NULL;    free_type(float_type_string);    float_type_string = NULL;    free_type(void_function_type_string);    void_function_type_string = NULL;    free_type(function_type_string);    function_type_string = NULL;    free_type(object_type_string);    object_type_string = NULL;
pike.git/src/pike_types.cmod:13324:    if (b_markers[e])    gc_mark_external (b_markers[e], " in b_markers");    }       if (string0_type_string)    gc_mark_external(string0_type_string, " as string0_type_string");    if (string_type_string)    gc_mark_external(string_type_string, " as string_type_string");    if (int_type_string)    gc_mark_external(int_type_string, " as int_type_string"); +  if (int0_type_string) +  gc_mark_external(int0_type_string, " as int0_type_string");    if (int_pos_type_string)    gc_mark_external(int_pos_type_string, " as int_pos_type_string");    if (object_type_string)    gc_mark_external(object_type_string, " as object_type_string");    if (program_type_string)    gc_mark_external(program_type_string, " as program_type_string");    if (float_type_string)    gc_mark_external(float_type_string, " as float_type_string");    if (mixed_type_string)    gc_mark_external(mixed_type_string, " as mixed_type_string");