It's been a while since I looked at this. I can't remember if that's a specific change or not. I do remember hitting some walls in trying to create clean code with what felt like sensible uses of `? super` ... places where I had to use explicit casts to make the compiler happy. Can't say if this was one of those.
On Wed, Aug 7, 2013 at 4:38 AM, Denis Stepanov <denis.stepa...@gmail.com>wrote: > Is there a reason why 'map' method in the Flow doesn't support instances > of the superclass mapper? > > Current signature: > > <X> Flow<X> map(Mapper<T, X> mapper); > > better: > > <X> Flow<X> map(Mapper<? super T, X> mapper); > > otherwise you can't write super mapper like <Integer>, <Long>, <Double> > ... map(numberToString) ... > > Also other methods could be improved: > > <A> A reduce(Reducer<? super A, T> reducer, A initial); > > <X, Y> Flow<Y> map(Mapper2<? super T, X, Y> mapper, Flow<? extends X> > flow); > > <X> Flow<X> mapcat(Mapper<? super T, Flow<X>> mapper); > > Denis > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@tapestry.apache.org > For additional commands, e-mail: dev-h...@tapestry.apache.org > > -- Howard M. Lewis Ship Creator of Apache Tapestry The source for Tapestry training, mentoring and support. Contact me to learn how I can get you up and productive in Tapestry fast! (971) 678-5210 http://howardlewisship.com