- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Traits & Context/View bounds on Type Parameters?
Thu, 2011-06-23, 16:08
/Hey guys,
I was just wondering why traits don't allow type parameters with
context / view bounds? Does anyone know?
Thu, 2011-06-23, 16:47
#2
Re: Traits & Context/View bounds on Type Parameters?
That makes sense. However, I feel like it would be useful in some cases if they were allowed.
Sent from my Verizon Wireless BlackBerry
-----Original Message-----
From: Jason Zaugg
Sender: scala-language@googlegroups.com
Date: Thu, 23 Jun 2011 17:35:23
To:
Reply-To: scala-language@googlegroups.com
Subject: Re: [scala-language] Traits & Context/View bounds on Type Parameters?
On Thu, Jun 23, 2011 at 5:08 PM, Michael Cotterell
wrote:
> /Hey guys,
>
> I was just wondering why traits don't allow type parameters with
> context / view bounds? Does anyone know?
Those bounds are desugared to implicit parameters, and traits don't
have a constructor parameter list to add them to.
-jason
Tue, 2011-06-28, 10:47
#3
Re: Traits & Context/View bounds on Type Parameters?
Michael,
Interesting related discussion that may help you:
http://scala-programming-language.1934581.n4.nabble.com/scala-2-8-type-p...
Rgds,
Alan
On Jun 23, 12:40 pm, mepcotter...@gmail.com wrote:
> That makes sense. However, I feel like it would be useful in some cases if they were allowed.
>
> Sent from my Verizon Wireless BlackBerry
>
>
>
>
>
>
>
> -----Original Message-----
> From: Jason Zaugg
>
> Sender: scala-language@googlegroups.com
> Date: Thu, 23 Jun 2011 17:35:23
> To:
> Reply-To: scala-language@googlegroups.com
> Subject: Re: [scala-language] Traits & Context/View bounds on Type Parameters?
>
> On Thu, Jun 23, 2011 at 5:08 PM, Michael Cotterell
> wrote:
> > /Hey guys,
>
> > I was just wondering why traits don't allow type parameters with
> > context / view bounds? Does anyone know?
>
> Those bounds are desugared to implicit parameters, and traits don't
> have a constructor parameter list to add them to.
>
> -jason
On Thu, Jun 23, 2011 at 5:08 PM, Michael Cotterell
wrote:
> /Hey guys,
>
> I was just wondering why traits don't allow type parameters with
> context / view bounds? Does anyone know?
Those bounds are desugared to implicit parameters, and traits don't
have a constructor parameter list to add them to.
-jason