[Python-bugs-list] [ python-Bugs-708205 ] math.fabs documentation is misleading
SourceForge.net
noreply@sourceforge.net
Mon, 28 Apr 2003 14:41:02 -0700
Bugs item #708205, was opened at 2003-03-22 19:26
Message generated for change (Settings changed) made by fdrake
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=708205&group_id=5470
Category: Documentation
Group: Python 2.2.2
>Status: Closed
>Resolution: Fixed
Priority: 5
Submitted By: George Yoshida (quiver)
Assigned to: Fred L. Drake, Jr. (fdrake)
Summary: math.fabs documentation is misleading
Initial Comment:
math.fabs documentation is misleading.
It says,
"Return the absolute value of the floating point number
x. ".
but I think it should look like this:
"Return the absolute value of x as a float."
See the code below.
>>> from math import *
>>> abs(3)
3
>>> fabs(3)
3.0
----------------------------------------------------------------------
Comment By: Tim Peters (tim_one)
Date: 2003-04-28 17:34
Message:
Logged In: YES
user_id=31435
Assigned to Fred. I removed words from the fabs docs, for
consistency with the other descriptions, and added a note
that *all* functions in this module return floats. There's
nothing special about math.fabs() in this respect, and I don't
want to end every description with "as a float". If you're
happy with this, please close the bug.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=708205&group_id=5470