pike.git / src / pike_types.c

version» Context lines:

pike.git/src/pike_types.c:5324:       case T_MULTISET:    case T_MAPPING:    /* FIXME: Why -1 and not 0?    *    * - There were complaints when people got compilation errors    * for indexing operations that would always fail.    */    return low_match_types(type->car, index_type, 0) ? 1 : -1;    +  case T_FUNCTION: +  while ((type = type->cdr) && (type->type == T_FUNCTION)) +  ; +  if (!type) return 0; +  +  /* FALL_THROUGH */ +  +  case T_MANY: +  type = type->cdr; +  if (!type || (type->type != T_OBJECT) || !type->car) +  return 0; +  /* function(... : object(is foo)) -- ie probably program(foo). */ +  +  /* FALL_THROUGH */ +    #ifdef AUTO_BIGNUM    case T_INT:   #endif    case T_PROGRAM:    return !!low_match_types(string_type_string, index_type, 0);       case T_MIXED:    return 1;       default: