[Python-Dev] trunc() (original) (raw)

Jeffrey Yasskin jyasskin at gmail.com
Sun Jan 27 01:00:21 CET 2008


On Jan 26, 2008 2:46 PM, Raymond Hettinger <python at rcn.com> wrote:

[Christian Heimes] > In my opinion float(complex) does do the most sensible thing. It fails > and points the user to abs().

Right.

To elaborate the point I was trying to make: If float() does not mean "the float part of" and should not take a complex argument (which I completely agree with), then int() does not mean "the int part of" and should not take a float argument.

Even assuming that's correct, I'm not certain that it's worth breaking (well, deprecating) backwards compatibility to achieve a more consistent set of functions in this case. I think it is, but I'm happy to leave that point up to the rest of the list (which does seem to be leaning against it).

-- Namasté, Jeffrey Yasskin



More information about the Python-Dev mailing list