diff options
author | Christian Heimes <christian@cheimes.de> | 2008-01-03 23:01:04 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-01-03 23:01:04 (GMT) |
commit | 072c0f1b7e3d83dec98313bc07ae92ed15fe7e6d (patch) | |
tree | f13fa3a4f9ebd69f276837569c27d65c847a5a01 /Doc/reference | |
parent | 1c9f4373d2fe9ce4f442c8066badb46850a543f3 (diff) | |
download | cpython-072c0f1b7e3d83dec98313bc07ae92ed15fe7e6d.zip cpython-072c0f1b7e3d83dec98313bc07ae92ed15fe7e6d.tar.gz cpython-072c0f1b7e3d83dec98313bc07ae92ed15fe7e6d.tar.bz2 |
Merged revisions 59666-59679 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59666 | christian.heimes | 2008-01-02 19:28:32 +0100 (Wed, 02 Jan 2008) | 1 line
Made vs9to8 Unix compatible
........
r59669 | guido.van.rossum | 2008-01-02 20:00:46 +0100 (Wed, 02 Jan 2008) | 2 lines
Patch #1696. Don't attempt to close None in dry-run mode.
........
r59671 | jeffrey.yasskin | 2008-01-03 03:21:52 +0100 (Thu, 03 Jan 2008) | 6 lines
Backport PEP 3141 from the py3k branch to the trunk. This includes r50877 (just
the complex_pow part), r56649, r56652, r56715, r57296, r57302, r57359, r57361,
r57372, r57738, r57739, r58017, r58039, r58040, and r59390, and new
documentation. The only significant difference is that round(x) returns a float
to preserve backward-compatibility. See http://bugs.python.org/issue1689.
........
r59672 | christian.heimes | 2008-01-03 16:41:30 +0100 (Thu, 03 Jan 2008) | 1 line
Issue #1726: Remove Python/atof.c from PCBuild/pythoncore.vcproj
........
r59675 | guido.van.rossum | 2008-01-03 20:12:44 +0100 (Thu, 03 Jan 2008) | 4 lines
Issue #1700, reported by Nguyen Quan Son, fix by Fredruk Lundh:
Regular Expression inline flags not handled correctly for some unicode
characters. (Forward port from 2.5.2.)
........
r59676 | christian.heimes | 2008-01-03 21:23:15 +0100 (Thu, 03 Jan 2008) | 1 line
Added math.isinf() and math.isnan()
........
r59677 | christian.heimes | 2008-01-03 22:14:48 +0100 (Thu, 03 Jan 2008) | 1 line
Some build bots don't compile mathmodule. There is an issue with the long definition of pi and euler
........
r59678 | christian.heimes | 2008-01-03 23:16:32 +0100 (Thu, 03 Jan 2008) | 2 lines
Modified PyImport_Import and PyImport_ImportModule to always use absolute imports by calling __import__ with an explicit level of 0
Added a new API function PyImport_ImportModuleNoBlock. It solves the problem with dead locks when mixing threads and imports
........
r59679 | christian.heimes | 2008-01-03 23:32:26 +0100 (Thu, 03 Jan 2008) | 1 line
Added copysign(x, y) function to the math module
........
Diffstat (limited to 'Doc/reference')
-rw-r--r-- | Doc/reference/datamodel.rst | 8 | ||||
-rw-r--r-- | Doc/reference/expressions.rst | 3 |
2 files changed, 6 insertions, 5 deletions
diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst index 0ec255f..3c7f8e6 100644 --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -152,7 +152,7 @@ Ellipsis object is accessed through the literal ``...`` or the built-in name ``Ellipsis``. Its truth value is true. -Numbers +:class:`numbers.Number` .. index:: object: numeric These are created by numeric literals and returned as results by arithmetic @@ -164,7 +164,7 @@ Numbers Python distinguishes between integers, floating point numbers, and complex numbers: - Integers + :class:`numbers.Integral` .. index:: object: integer These represent elements from the mathematical set of integers (positive and @@ -202,7 +202,7 @@ Numbers operation except left shift, if it yields a result in the plain integer domain without causing overflow, will yield the same result when using mixed operands. - Floating point numbers + :class:`numbers.Real` (:class:`float`) .. index:: object: floating point pair: floating point; number @@ -217,7 +217,7 @@ Numbers overhead of using objects in Python, so there is no reason to complicate the language with two kinds of floating point numbers. - Complex numbers + :class:`numbers.Complex` .. index:: object: complex pair: complex; number diff --git a/Doc/reference/expressions.rst b/Doc/reference/expressions.rst index 6e160ee..cf95636 100644 --- a/Doc/reference/expressions.rst +++ b/Doc/reference/expressions.rst @@ -768,7 +768,8 @@ float result is delivered. For example, ``10**2`` returns ``100``, but ``10**-2`` returns ``0.01``. Raising ``0.0`` to a negative power results in a :exc:`ZeroDivisionError`. -Raising a negative number to a fractional power results in a :exc:`ValueError`. +Raising a negative number to a fractional power results in a :class:`complex` +number. (Since Python 2.6. In earlier versions it raised a :exc:`ValueError`.) .. _unary: |