Is there a formal relation ship between std::copy with and without an execution policy argument? Either in practice or in the standard.
For example, would it be the case that
namespace std{
template<class It>
It copy(std::execution::sequenced_policy, It first, It last, It d_first){
return std::copy(first, last, d_first);
}
}
or
namespace std{
template<class It>
It copy(std::execution::sequenced_policy, It first, It last, It d_first){
// using std::copy; // may not be needed
return copy(first, last, d_first);
}
}
Note that in the first version mean that I need to overload copy(par::seq, ...) as well.
or is the case that
namespace std{
template<class It>
It copy(std::execution::sequenced_policy, It first, It last, It d_first){
... not defined at all in terms of other `copy(It, ...)` or `std::copy(It, ...)`
}
}
The reason is that I want to ADL overload the copy algorithm (in a custom namespace) for a special kind of iterator.
Aucun commentaire:
Enregistrer un commentaire