A collection of LinearSeqLike

Dear All,I would like to implement something like thatclass MultipleCollection[A](items:IndexedSeq[LinearSeqLike[A,_]){
def filter = new example(items.map(_.filter)); }
this does not work because the _ is resolved to Any, and therefore filter returns any.
How does one solve this?
Best Regards
Edmondo

Re: A collection of LinearSeqLike

What is the problem of adding a B to the type parameters and writing
LienarSeqLike[A, B]?

On Tue, Jan 24, 2012 at 13:36, Edmondo Porcu wrote:
> Dear All,
> I would like to implement something like that
> class MultipleCollection[A](items:IndexedSeq[LinearSeqLike[A,_]){
>
> def filter = new example(items.map(_.filter));
> }
>
> this does not work because the _ is resolved to Any, and therefore filter
> returns any.
>
> How does one solve this?
>
> Best Regards
>
> Edmondo

Copyright © 2013 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland