Lines Matching refs:array
382 Type *array;
389 array = static_array;
392 inline Type& operator [] (unsigned int i) { return array[i]; }
393 inline const Type& operator [] (unsigned int i) const { return array[i]; }
400 return &array[len - 1];
415 if (array == static_array) {
418 memcpy (new_array, array, len * sizeof (Type));
422 new_array = (Type *) realloc (array, new_allocated * sizeof (Type));
429 array = new_array;
446 memmove (static_cast<void *> (&array[i]),
447 static_cast<void *> (&array[i + 1]),
461 if (array[i] == v)
462 return &array[i];
468 if (array[i] == v)
469 return &array[i];
475 ::qsort (array, len, sizeof (Type), Type::cmp);
480 ::qsort (array + start, end - start, sizeof (Type), Type::cmp);
487 return bfind (x, &i) ? &array[i] : nullptr;
493 return bfind (x, &i) ? &array[i] : nullptr;
502 int c = this->array[mid].cmp (x);
513 if (max < 0 || (max < (int) this->len && this->array[max].cmp (x) > 0))
521 if (array != static_array)
522 free (array);
523 array = nullptr;
725 hb_stable_sort (T *array, unsigned int len, int(*compar)(const T *, const T *), T2 *array2)
730 while (j && compar (&array[j - 1], &array[i]) > 0)
736 T t = array[i];
737 memmove (&array[j + 1], &array[j], (i - j) * sizeof (T));
738 array[j] = t;
750 hb_stable_sort (T *array, unsigned int len, int(*compar)(const T *, const T *))
752 hb_stable_sort (array, len, compar, (int *) nullptr);
869 /* Size signifying variable-sized array */