Входные данные:
1. ProductVersion - класс.
2. typedef std::set <ProductVersion, ProductVersionListComparator> ProductVersionList - контейнер.
3. Функция, в которую передается ProductVersion и она должна вернуть ProductVersionList со всеми элементами, большими, чем этот.
Вот текущий вариант
ProductVersionList AbstractUpdateConfig::availableUpdates (const ProductVersion ¤tProductVersion_) const
{
ProductVersionList l;
if (productVersionList_.empty () || currentProductVersion_.empty ()) {
return l;
}
const ProductVersionList::const_iterator &it = productVersionList_.lower_bound (currentProductVersion_);
if (it != productVersionList_.begin ()) {
l.insert (productVersionList_.begin (), it);
}
return l;
}
А как его через copy_if провернуть?