id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 2893,Function Input Iterator,anonymous,Dave Abrahams,"Simply put a the function input iterator implementation wraps a nullary function object and allows for bounded iterators using an embedded state variable. The use case is for something like the following: {{{ struct generator { typedef int result_type; generator() { srand(time(0)); } result_type operator() () const { return rand(); } }; using namespace std; using namespace boost; int main(int argc, char * argv[]) { generator f; copy( make_function_input_iterator(f, infinite()), make_function_input_iterator(f, infinite()), ostream_iterator(cout, "" "") ); return 0; } }}} And if you don't want an infinite range, you can simply bound it: {{{ copy( make_function_input_iterator(f, 0), make_function_input_iterator(f, 10), ostream_iterator(cout, "" "") ); }}} ",Library Submissions,closed,To Be Determined,iterator,,Not Applicable,fixed,iterator function input,mikhailberis@…