[Python-ideas] Why no sign function?
Nick Coghlan
ncoghlan at gmail.com
Tue Apr 27 15:29:57 CEST 2010
Mark Dickinson wrote:
> Would this be of value to anyone? I'd only vote +0, since I don't
> feel a great need for this function.
I'm in a similar position. I was merely commenting that *if* we did
anything, a C99 inspired math.signbit would probably be the thing to add.
(I don't see the value of the 3 way comparison, since that doesn't
suffer any signed zero oddities, and hence, NaN values aside, can be
handled with the ordinary comparison operators).
Cheers,
Nick.
--
Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
---------------------------------------------------------------
More information about the Python-ideas
mailing list