• Home
  • Raw
  • Download

Lines Matching refs:working

166     Vec working(data, data + size);  in sort()  local
167 std::sort(working.begin(), working.end()); in sort()
169 if (!std::is_sorted(working.begin(), working.end())) return 1; in sort()
170 if (!fuzzing::is_permutation(data, data + size, working.cbegin())) return 99; in sort()
181 StableVec working = input; in stable_sort() local
182 std::stable_sort(working.begin(), working.end(), key_less()); in stable_sort()
184 if (!std::is_sorted(working.begin(), working.end(), key_less())) return 1; in stable_sort()
185 auto iter = working.begin(); in stable_sort()
186 while (iter != working.end()) in stable_sort()
188 auto range = std::equal_range(iter, working.end(), *iter, key_less()); in stable_sort()
192 if (!fuzzing::is_permutation(input.cbegin(), input.cend(), working.cbegin())) return 99; in stable_sort()
199 Vec working(data, data + size); in partition() local
200 auto iter = std::partition(working.begin(), working.end(), is_even<uint8_t>()); in partition()
202 if (!std::all_of (working.begin(), iter, is_even<uint8_t>())) return 1; in partition()
203 if (!std::none_of(iter, working.end(), is_even<uint8_t>())) return 2; in partition()
204 if (!fuzzing::is_permutation(data, data + size, working.cbegin())) return 99; in partition()
253 StableVec working = input; in stable_partition() local
254 auto iter = std::stable_partition(working.begin(), working.end(), is_even<stable_test>()); in stable_partition()
256 if (!std::all_of (working.begin(), iter, is_even<stable_test>())) return 1; in stable_partition()
257 if (!std::none_of(iter, working.end(), is_even<stable_test>())) return 2; in stable_partition()
258 if (!std::is_sorted(working.begin(), iter, payload_less())) return 3; in stable_partition()
259 if (!std::is_sorted(iter, working.end(), payload_less())) return 4; in stable_partition()
260 if (!fuzzing::is_permutation(input.cbegin(), input.cend(), working.cbegin())) return 99; in stable_partition()
270 Vec working(data + 1, data + size); in nth_element() local
271 const auto partition_iter = working.begin() + partition_point; in nth_element()
272 std::nth_element(working.begin(), partition_iter, working.end()); in nth_element()
275 if (partition_iter == working.end()) in nth_element()
277 if (!std::equal(data + 1, data + size, working.begin())) return 98; in nth_element()
282 if (!std::all_of(working.begin(), partition_iter, [=](uint8_t v) { return v <= nth; })) in nth_element()
284 if (!std::all_of(partition_iter, working.end(), [=](uint8_t v) { return v >= nth; })) in nth_element()
286 if (!fuzzing::is_permutation(data + 1, data + size, working.cbegin())) return 99; in nth_element()
298 Vec working(data + 1, data + size); in partial_sort() local
299 const auto sort_iter = working.begin() + sort_point; in partial_sort()
300 std::partial_sort(working.begin(), sort_iter, working.end()); in partial_sort()
302 if (sort_iter != working.end()) in partial_sort()
304 const uint8_t nth = *std::min_element(sort_iter, working.end()); in partial_sort()
305 if (!std::all_of(working.begin(), sort_iter, [=](uint8_t v) { return v <= nth; })) in partial_sort()
307 if (!std::all_of(sort_iter, working.end(), [=](uint8_t v) { return v >= nth; })) in partial_sort()
310 if (!std::is_sorted(working.begin(), sort_iter)) return 3; in partial_sort()
311 if (!fuzzing::is_permutation(data + 1, data + size, working.cbegin())) return 99; in partial_sort()
373 Vec working(data, data + size); in unique() local
374 std::sort(working.begin(), working.end()); in unique()
375 Vec results = working; in unique()
382 return working.size() == 0 ? 0 : 1; in unique()
398 if (std::find(working.begin(), working.end(), *it) == working.end()) in unique()
402 for (auto v : working) in unique()
412 Vec working(data, data + size); in unique_copy() local
413 std::sort(working.begin(), working.end()); in unique_copy()
415 (void) std::unique_copy(working.begin(), working.end(), in unique_copy()
422 return working.size() == 0 ? 0 : 1; in unique_copy()
438 if (std::find(working.begin(), working.end(), v) == working.end()) in unique_copy()
442 for (auto v : working) in unique_copy()
506 Vec working(data, data + size); in make_heap() local
507 std::make_heap(working.begin(), working.end()); in make_heap()
509 if (!std::is_heap(working.begin(), working.end())) return 1; in make_heap()
510 if (!fuzzing::is_permutation(data, data + size, working.cbegin())) return 99; in make_heap()
519 Vec working(data, data + size); in push_heap() local
520 auto iter = working.begin() + (size / 2); in push_heap()
521 std::make_heap(working.begin(), iter); in push_heap()
522 if (!std::is_heap(working.begin(), iter)) return 1; in push_heap()
526 for (; iter != working.end(); ++iter) { in push_heap()
527 std::push_heap(working.begin(), iter); in push_heap()
528 if (!std::is_heap(working.begin(), iter)) return 2; in push_heap()
531 if (!fuzzing::is_permutation(data, data + size, working.cbegin())) return 99; in push_heap()
538 Vec working(data, data + size); in pop_heap() local
539 std::make_heap(working.begin(), working.end()); in pop_heap()
542 auto iter = --working.end(); in pop_heap()
543 while (iter != working.begin()) { in pop_heap()
544 std::pop_heap(working.begin(), iter); in pop_heap()
545 if (!std::is_heap(working.begin(), --iter)) return 2; in pop_heap()