Using operator(), std::generate, and iterators