[concurrency-interest] Executors change from JDK5 to JDK6

Neal Gafter neal at gafter.com
Mon May 5 14:15:13 EDT 2008


In an argument position it is almost always worth it.

On Mon, May 5, 2008 at 11:04 AM, Tom Hawtin <Thomas.Hawtin at sun.com> wrote:

> Neal Gafter wrote:
>
> >
> > *<T> List<Future<T>> invokeAll(Collection<Callable<T>> tasks)*
> >
> > In SE 6 it was
> >
> > *<T> List<Future<T>> invokeAll(Collection<? extends Callable<T>> tasks)*
> >
> > The correct signature should be
> >
> > *<T> List<Future<T>> invokeAll(Collection<? extends Callable<? extends
> > T>> tasks)*
> >
>
> There are lots of places where something like that could be done. For
> instance in CompletionService<V>:
>
>  Future<V> submit(Callable<? extends V> task);
>
> How does one determine whether inserting a wildcard is worth it?
>
> Tom Hawtin
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/attachments/20080505/a440b1ba/attachment.html 


More information about the Concurrency-interest mailing list