Skip to content

num::swap_remove

Defined in header <container/swap_remove.hpp>

template <typename T>
void swap_remove(array<T> &values, view<const idx> removed);

Apply swap_remove_plan to one array, shrinking it in place.

Elements are moved, not copied, so this is as cheap for a container element as for a scalar one.