I am trying to use tbb::parallel_sort
to sort 2 arrays at the same time. Intel\'s documentation here says https://software.intel.com/en-us/node/506167 The req
The first error reads "no appropriate default constructor available..", but Iterators must be default constructible.
Whether the default construction is used in one algorithm or another doesn't matter, the requirement still holds. So compilation success with std::sort
and failure with tbb::parallel_sort
doesn't mean the The requirements on the iterator and sequence are the same as for std::sort
isn't true; it just means that the implementation of std::sort
that you are using doesn't rely on that pre-requisite.
If you implement your iterator to conform to the subset of standard that is relied upon by both algorithms, then it should work, per the documentation.