In this post:
set_intersection
uses std::inserter
as follows:
std::set_intersection(
netSet.begin(), netSet.end(),
portSet.begin(), portSet.end(),
std::inserter(result, result.end())
);
However, std::inserter
is no longer available with C++17
so how should this code be rewritten?
EDIT: As many have pointed out, std::inserter is still available in C++17. Somehow I ended up reading how std::iterator had been deprecated not realising that it wasn't referring to std::inserter. My problem was solved by specifically including the <iterator>
header in my code.
std::inserter
is no longer available with c++17
That's not true!
There is no indication that std::inserter
will be removed from C++17, or that it will become deprecated.
I was getting confused with
std::iterator