On Thu, 4 Mar 2004, Dave Rolsky wrote: > > $set2 = $set->set_map( sub { > > $_[0]->add( hours => 1 ); > > return; > > } > > ); > > # same as before. > > Hmm, this does encourage the "map in void context" idiom, which is > unfortunate. In this case, $set2 would be an empty set. Maybe we should > leave iterate() in as well, since map in a void context is discouraged in > Perl.
Actually, this doesn't encourage it and we _still_ need iterate() for sure. We can have set_map() only be used to create a new set, and iterate() only be used to alter the current set in place. -dave /*======================= House Absolute Consulting www.houseabsolute.com =======================*/