This code compiles on recent gcc and clang:
#include <iterator>
#include <vector>
int main(int argc, char** argv)
{
std::vector<int> v(20);
fill(begin(v), end(v), 0);
return EXIT_SUCCESS;
}
But surely it SHOULD NOT.
Don't I need std::fill(std::begin(v), std::end(v), 0);
?
What's changed? Why are these functions in the global namespace?