On Tue, Jul 23, 2013 at 6:51 AM, James Roper <notifications@github.com>wrote:

> In framework/src/play-json/src/main/scala/play/api/libs/json/JsValue.scala:
>
> > @@ -95,7 +92,14 @@ case object JsNull extends JsValue
> >  /**
> >   * Represent a missing Json value.
> >   */
> > -case class JsUndefined(error: String) extends JsValue
> > +class JsUndefined(err: => String) extends JsValue {
> > +  def error = err
> > +}
>
> What should the implementation of equals for JsUndefined be? To me, it
> seems that it should always return false. I thought about implementing
> this, but wasn't sure about the consequences of doing so (eg if you put it
> in a set, it would be lost).
>
I would tend to think as you : the equals should return false. But do we
also need it???
We need an extractor, it's clear but hashCode and equals, I wonder?

JsUndefined is purely technical, not at all in Json std and shouldn't be
used by users.

As for toString, yes, it it should be implemented.
>
yes just return the message



>  —
> Reply to this email directly or view it on GitHub<https://github.com/playframework/playframework/pull/1350/files#r5337403>
> .
>