- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Re: Detect if AnyVal or AnyRef
>>>>> "Naftoli" == Naftoli Gugenheim writes:
Naftoli> Not bad. Is there no better way, tough?
Can you tell us about the context in which you are wanting to do this?
Perhaps we can help you avoid it altogether.










Re: Detect if AnyVal or AnyRef
On Mon, Jan 12, 2009 at 2:04 PM, Seth Tisue <seth [at] tisue [dot] net> wrote:
I think that I already have (this came up a while ago and I just didn't get around to asking it before), but that isn't the answer to my question. :) Maybe the answer is that there is no (known) need to do so and therefore you can't, except by using a hack with implicits. :)
Although it probably had to do with my project that I mentioned in the thread about pattern matching on class literals, or more specifically, after parsing expressions, determining in advance the type of the expression, for use e.g. in selecting an overloaded method.
Re: Detect if AnyVal or AnyRef
sealed trait Exp
case class IntExp extends Exp
//etc
It looks like
sealed trait Exp[T]
case class IntExp extends Exp[Int]
case class JIntExp extends Exp[java.lang.Integer]
// etc
On Mon, Jan 12, 2009 at 11:29 AM, Naftoli Gugenheim <naftoligug [at] gmail [dot] com> wrote:
Re: Detect if AnyVal or AnyRef
Anyway, I'm not so sure that this was where it came up.
In any case, anyone that's interested in the project can join the mailing list at http://appbuilder.dev.java.net.
On Mon, Jan 12, 2009 at 4:12 PM, James Iry <jamesiry [at] gmail [dot] com> wrote:
Re: Detect if AnyVal or AnyRef
HTTP 403
Most likely causes:
This website requires you to log in.
On Tue, Jan 13, 2009 at 11:57 AM, Naftoli Gugenheim <naftoligug [at] gmail [dot] com> wrote: