Open dzhang314 opened 5 years ago
I think it's just left over from the Float64 implementation. Sorry I didn't answer sooner, but Github refuses to notify me about anything, even on my own packages... I wonder if your suggestion could trip up other number packages? :)
Hey, I'm the author of MultiFloats.jl, a new Julia package for extended precision arithmetic. I'd like to make my
MultiFloat{T,N}
type compatible with Optim.jl, but unfortunately I don't have an implementation oflog2(::MultiFloat)
yet, which trips up this one line in hagerzhang.jl:Is there any reason that this couldn't be replaced with
precision(T)-1
or-exponent(eps(T))
, to allow floating-point types that don't havelog2
implemented? Of course I'm also working on implementing transcendental functions in MultiFloat.jl, but for the simple task of getting the exponent of epsilon, I figure a call to a transcendental function is unnecessary anyway.