JuliaMath / NaNMath.jl

Julia math built-ins which return NaN and accumulator functions which ignore NaN
Other
52 stars 26 forks source link

pow errors out for vector call #8

Closed davidanthoff closed 8 years ago

davidanthoff commented 8 years ago

This

NaNMath.pow([1.], 3.)

causes a stack overflow. It should probably either work, or throw a method not defined error, right?

mlubin commented 8 years ago

Replacing

pow(x,y) = pow(float(x),float(y))

with

pow(x::Number,y::Number) = pow(float(x),float(y))

should force it to give a method error.

davidanthoff commented 8 years ago

Yes, I think that would do it. Should I open a PR, or is it easier if you just commit this right away?

davidanthoff commented 8 years ago

Thanks!