]> granicus.if.org Git - python/commitdiff
Remove mentions of "long integer" in the docs.
authorGeorg Brandl <georg@python.org>
Thu, 29 Nov 2007 17:24:34 +0000 (17:24 +0000)
committerGeorg Brandl <georg@python.org>
Thu, 29 Nov 2007 17:24:34 +0000 (17:24 +0000)
Credits to HappySmileMan from GHOP.

14 files changed:
Doc/library/_winreg.rst
Doc/library/array.rst
Doc/library/bz2.rst
Doc/library/easydialogs.rst
Doc/library/exceptions.rst
Doc/library/functions.rst
Doc/library/marshal.rst
Doc/library/pickle.rst
Doc/library/repr.rst
Doc/library/stdtypes.rst
Doc/library/struct.rst
Doc/reference/datamodel.rst
Doc/reference/lexical_analysis.rst
Doc/using/cmdline.rst

index 033446f1b81cf181e269aaa06914d830403570db..1a384fe083773862da4c527663e158a388b82a4c 100644 (file)
@@ -219,7 +219,7 @@ This module offers the following functions:
    | ``1`` | An integer giving the number of values this |
    |       | key has.                                    |
    +-------+---------------------------------------------+
-   | ``2`` | A long integer giving when the key was last |
+   | ``2`` | An integer giving when the key was last     |
    |       | modified (if available) as 100's of         |
    |       | nanoseconds since Jan 1, 1600.              |
    +-------+---------------------------------------------+
index 4747b637581e72da1edf62010456e811f9e332b2..e86d0cce88ef6cbace597f5b172f1d4702603427 100644 (file)
@@ -45,10 +45,7 @@ defined:
 
 The actual representation of values is determined by the machine architecture
 (strictly speaking, by the C implementation).  The actual size can be accessed
-through the :attr:`itemsize` attribute.  The values stored  for ``'L'`` and
-``'I'`` items will be represented as Python long integers when retrieved,
-because Python's plain integer type cannot represent the full range of C's
-unsigned (long) integers.
+through the :attr:`itemsize` attribute.
 
 The module defines the following type:
 
index ff3c773a358388a8e8bc6f312125b2fddabd2113..ac1695bee3da751aa94c76b0a1a70e670a984c10 100644 (file)
@@ -99,7 +99,7 @@ Handling of compressed files is offered by the :class:`BZ2File` class.
 
 .. method:: BZ2File.tell()
 
-   Return the current file position, an integer (may be a long integer).
+   Return the current file position, an integer.
 
 
 .. method:: BZ2File.write(data)
index dbc996c72305aa0a038387545e7e09bdac32d142..2a3b66be72e9b5dedb0f0646d82a2967f1ffe9ae 100644 (file)
@@ -160,14 +160,14 @@ does not occur until the progress bar is next updated, typically via a call to
 
 .. attribute:: ProgressBar.curval
 
-   The current value (of type integer or long integer) of the progress bar.  The
+   The current value (of type integer) of the progress bar.  The
    normal access methods coerce :attr:`curval` between ``0`` and :attr:`maxval`.
    This attribute should not be altered directly.
 
 
 .. attribute:: ProgressBar.maxval
 
-   The maximum value (of type integer or long integer) of the progress bar; the
+   The maximum value (of type integer) of the progress bar; the
    progress bar (thermometer style) is full when :attr:`curval` equals
    :attr:`maxval`.  If :attr:`maxval` is ``0``, the bar will be indeterminate
    (barber-pole).  This attribute should not be altered directly.
index 9453b7acae10490f4d8fea253d31fa862635e453..5620b1b31aa9bfb9b097df508bc77039a2c31764 100644 (file)
@@ -217,7 +217,7 @@ The following exceptions are the exceptions that are actually raised.
 .. exception:: OverflowError
 
    Raised when the result of an arithmetic operation is too large to be
-   represented.  This cannot occur for long integers (which would rather raise
+   represented.  This cannot occur for integers (which would rather raise
    :exc:`MemoryError` than give up).  Because of the lack of standardization of
    floating point exception handling in C, most floating point operations also
    aren't checked.
index 08566facf4d447a46d44f11d9e19067d8f141c7b..423625388b23c986e9011fdd07ab2d3ed2ece47c 100644 (file)
@@ -65,7 +65,7 @@ available.  They are listed here in alphabetical order.
 
 .. function:: abs(x)
 
-   Return the absolute value of a number.  The argument may be a plain or long
+   Return the absolute value of a number.  The argument may be an
    integer or a floating point number.  If the argument is a complex number, its
    magnitude is returned.
 
@@ -320,8 +320,8 @@ available.  They are listed here in alphabetical order.
 
    Take two (non complex) numbers as arguments and return a pair of numbers
    consisting of their quotient and remainder when using long division.  With mixed
-   operand types, the rules for binary arithmetic operators apply.  For plain and
-   long integers, the result is the same as ``(a // b, a % b)``. For floating point
+   operand types, the rules for binary arithmetic operators apply.  For integers, 
+   the result is the same as ``(a // b, a % b)``. For floating point
    numbers the result is ``(q, a % b)``, where *q* is usually ``math.floor(a / b)``
    but may be 1 less than that.  In any case ``q * b + a % b`` is very close to
    *a*, if ``a % b`` is non-zero it has the same sign as *b*, and ``0 <= abs(a % b)
@@ -435,7 +435,7 @@ available.  They are listed here in alphabetical order.
 
    Convert a string or a number to floating point.  If the argument is a string, it
    must contain a possibly signed decimal or floating point number, possibly
-   embedded in whitespace. Otherwise, the argument may be a plain or long integer
+   embedded in whitespace. Otherwise, the argument may be an integer
    or a floating point number, and a floating point number with the same value
    (within Python's floating point precision) is returned.  If no argument is
    given, returns ``0.0``.
@@ -530,7 +530,7 @@ available.  They are listed here in alphabetical order.
 
 .. function:: id(object)
 
-   Return the "identity" of an object.  This is an integer (or long integer) which
+   Return the "identity" of an object.  This is an integer which
    is guaranteed to be unique and constant for this object during its lifetime.
    Two objects with non-overlapping lifetimes may have the same :func:`id` value.
    (Implementation note: this is the address of the object.)
@@ -783,7 +783,7 @@ available.  They are listed here in alphabetical order.
    form ``pow(x, y)`` is equivalent to using the power operator: ``x**y``.
 
    The arguments must have numeric types.  With mixed operand types, the coercion
-   rules for binary arithmetic operators apply.  For int and long int operands, the
+   rules for binary arithmetic operators apply.  For :class:`int` operands, the
    result has the same type as the operands (after coercion) unless the second
    argument is negative; in that case, all arguments are converted to float and a
    float result is delivered.  For example, ``10**2`` returns ``100``, but
index bc431843d97488dc8d0bc54b06717c30a2c6e96a..8f669b267fb83bef43d494bbc722a1146aa51ce0 100644 (file)
@@ -37,24 +37,13 @@ supports a substantially wider range of objects than marshal.
 
 Not all Python object types are supported; in general, only objects whose value
 is independent from a particular invocation of Python can be written and read by
-this module.  The following types are supported: ``None``, integers, long
-integers, floating point numbers, strings, Unicode objects, tuples, lists, sets,
+this module.  The following types are supported: ``None``, integers,
+floating point numbers, strings, Unicode objects, tuples, lists, sets,
 dictionaries, and code objects, where it should be understood that tuples, lists
 and dictionaries are only supported as long as the values contained therein are
 themselves supported; and recursive lists and dictionaries should not be written
 (they will cause infinite loops).
 
-.. warning::
-   
-   On machines where C's ``long int`` type has more than 32 bits (such as the
-   DEC Alpha), it is possible to create plain Python integers that are longer
-   than 32 bits. If such an integer is marshaled and read back in on a machine
-   where C's ``long int`` type has only 32 bits, a Python long integer object
-   is returned instead.  While of a different type, the numeric value is the
-   same.  (This behavior is new in Python 2.2.  In earlier versions, all but the
-   least-significant 32 bits of the value were lost, and a warning message was
-   printed.)
-
 There are functions that read/write files as well as functions operating on
 strings.
 
index e18693735c9d185f304aeb672f598b83189878dc..c88fc299d79f16db1d5beeda32a9475a77a69fac 100644 (file)
@@ -328,7 +328,7 @@ The following types can be pickled:
 
 * ``None``, ``True``, and ``False``
 
-* integers, long integers, floating point numbers, complex numbers
+* integers, floating point numbers, complex numbers
 
 * normal and Unicode strings
 
index 0ad08c6365edd65b6ec9d01a8f0f300c449a267e..3f7fc227a0e08c0f1ae8cf5c76f255c3a6c09b01 100644 (file)
@@ -65,7 +65,7 @@ which format specific object types.
 
 .. attribute:: Repr.maxlong
 
-   Maximum number of characters in the representation for a long integer.  Digits
+   Maximum number of characters in the representation for an integer.  Digits
    are dropped from the middle.  The default is ``40``.
 
 
index 4f09205cc1474e7bc11223b1ec74bb0b67cdb3ba..e94560b89f2c532db527248999b762e0ae0d1bfc 100644 (file)
@@ -246,7 +246,6 @@ and imaginary parts.
 .. index::
    single: arithmetic
    builtin: int
-   builtin: long
    builtin: float
    builtin: complex
 
@@ -326,7 +325,7 @@ Notes:
       pair: numeric; conversions
       pair: C; language
 
-   Conversion from floating point to (long or plain) integer may round or truncate
+   Conversion from floating point to integer may round or truncate
    as in C; see functions :func:`floor` and :func:`ceil` in the :mod:`math` module
    for well-defined conversions.
 
index b28f9b4ed089ffac0b25c73cadc1ed7bee9bbca1..9e527f15115654dfbb10c79adf8dfbe37c8d265e 100644 (file)
@@ -81,15 +81,15 @@ Python values should be obvious given their types:
 +--------+-------------------------+--------------------+-------+
 | ``i``  | :ctype:`int`            | integer            |       |
 +--------+-------------------------+--------------------+-------+
-| ``I``  | :ctype:`unsigned int`   | long               |       |
+| ``I``  | :ctype:`unsigned int`   | integer            |       |
 +--------+-------------------------+--------------------+-------+
 | ``l``  | :ctype:`long`           | integer            |       |
 +--------+-------------------------+--------------------+-------+
-| ``L``  | :ctype:`unsigned long`  | long               |       |
+| ``L``  | :ctype:`unsigned long`  | integer            |       |
 +--------+-------------------------+--------------------+-------+
-| ``q``  | :ctype:`long long`      | long               | \(2)  |
+| ``q``  | :ctype:`long long`      | integer            | \(2)  |
 +--------+-------------------------+--------------------+-------+
-| ``Q``  | :ctype:`unsigned long   | long               | \(2)  |
+| ``Q``  | :ctype:`unsigned long   | integer            | \(2)  |
 |        | long`                   |                    |       |
 +--------+-------------------------+--------------------+-------+
 | ``f``  | :ctype:`float`          | float              |       |
@@ -139,16 +139,7 @@ count-1, it is padded with null bytes so that exactly count bytes in all are
 used.  Note that for :func:`unpack`, the ``'p'`` format character consumes count
 bytes, but that the string returned can never contain more than 255 characters.
 
-For the ``'I'``, ``'L'``, ``'q'`` and ``'Q'`` format characters, the return
-value is a Python long integer.
 
-For the ``'P'`` format character, the return value is a Python integer or long
-integer, depending on the size needed to hold a pointer when it has been cast to
-an integer type.  A *NULL* pointer will always be returned as the Python integer
-``0``. When packing pointer-sized values, Python integer or long integer objects
-may be used.  For example, the Alpha and Merced processors use 64-bit pointer
-values, meaning a Python long integer will be used to hold the pointer; other
-platforms use 32-bit pointers and will use a Python integer.
 
 For the ``'t'`` format character, the return value is either :const:`True` or
 :const:`False`. When packing, the truth value of the argument object is used.
index 68e9f104727030aa8aa6fece6ab43eb9e1e15968..f33df0bbc4e75082b252d69d887416ed38ccb2ed 100644 (file)
@@ -177,18 +177,6 @@ Numbers
             object: plain integer
             single: OverflowError (built-in exception)
 
-         These represent numbers in the range -2147483648 through 2147483647. (The range
-         may be larger on machines with a larger natural word size, but not smaller.)
-         When the result of an operation would fall outside this range, the result is
-         normally returned as a long integer (in some cases, the exception
-         :exc:`OverflowError` is raised instead). For the purpose of shift and mask
-         operations, integers are assumed to have a binary, 2's complement notation using
-         32 or more bits, and hiding no bits from the user (i.e., all 4294967296
-         different bit patterns correspond to different values).
-
-      Long integers
-         .. index:: object: long integer
-
          These represent numbers in an unlimited range, subject to available (virtual)
          memory only.  For the purpose of shift and mask operations, a binary
          representation is assumed, and negative numbers are represented in a variant of
@@ -210,11 +198,9 @@ Numbers
       .. index:: pair: integer; representation
 
       The rules for integer representation are intended to give the most meaningful
-      interpretation of shift and mask operations involving negative integers and the
-      least surprises when switching between the plain and long integer domains.  Any
+      interpretation of shift and mask operations involving negative integers.  Any
       operation except left shift, if it yields a result in the plain integer domain
-      without causing overflow, will yield the same result in the long integer domain
-      or when using mixed operands.
+      without causing overflow, will yield the same result when using mixed operands.
 
       .. % Integers
 
index 37ef6072bae955eb6fb1a7ddf347b48794acd9ba..1b315a648eade4fd6bd73ba2641f72c6dac2effa 100644 (file)
@@ -567,12 +567,12 @@ styles for each component (even mixing raw strings and triple quoted strings).
 Numeric literals
 ----------------
 
-.. index:: number, numeric literal, integer literal, plain integer literal
-   long integer literal, floating point literal, hexadecimal literal
+.. index:: number, numeric literal, integer literal
+   floating point literal, hexadecimal literal
    octal literal, binary literal, decimal literal, imaginary literal, complex literal
 
-There are four types of numeric literals: plain integers, long integers,
-floating point numbers, and imaginary numbers.  There are no complex literals
+There are three types of numeric literals: plain integers, floating point
+numbers, and imaginary numbers.  There are no complex literals
 (complex numbers can be formed by adding a real number and an imaginary number).
 
 Note that numeric literals do not include a sign; a phrase like ``-1`` is
index 7ee9c040467701f2d175b779304718f55b04906e..18e6c6826a9195df593f29360e6d230f5d8ffcfe 100644 (file)
@@ -171,13 +171,12 @@ Miscellaneous options
 
    Division control. The argument must be one of the following:
    
-   ``old``
-     division of int/int and long/long return an int or long (*default*)
    ``new``
-     new division semantics, i.e. division of int/int and long/long returns a
-     float
+     new division semantics, i.e. division of int/int returns a float (*default*)
+   ``old``
+     division of int/int returns an int
    ``warn``
-     old division semantics with a warning for int/int and long/long
+     old division semantics with a warning for int/int
    ``warnall``
      old division semantics with a warning for all uses of the division operator