It's converting an object that is not a number into NaN, which literally is
intended to represent the case when something is Not a Number.  Converting
it to 0 would be different because something which is not a number would
not necessarily be 0.

I would like it to not result in an error because Doubles can represent
this situation without resorting to an error.

On Mon, Oct 31, 2016 at 11:44 AM, Otto Fowler <[email protected]>
wrote:

> There is no difference between converting null to NaN or 0.d.  It is still
> converting no value to some value right?
>
>
> On October 31, 2016 at 11:40:52, Otto Fowler ([email protected])
> wrote:
>
> @Test(expected = ParseException.class)
> > public void testMissingVariables() {
> > String query = "1 + cannot + add + missing + variables";
> > run(query, new HashMap<>());
> > }
>
>

Reply via email to