]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Issue #16192: Clarify when c_int is an alias to c_long in ctypes documentation
authorBerker Peksag <berker.peksag@gmail.com>
Thu, 2 Jun 2016 19:17:51 +0000 (12:17 -0700)
committerBerker Peksag <berker.peksag@gmail.com>
Thu, 2 Jun 2016 19:17:51 +0000 (12:17 -0700)
Doc/library/ctypes.rst

index 1d45a37f119a6629ca1175d602c1cdd41f45ef60..521b8b9b1d44062da8f6cd77e9b2ccc7cfdd93c2 100644 (file)
@@ -20,11 +20,10 @@ Note: The code samples in this tutorial use :mod:`doctest` to make sure that
 they actually work.  Since some code samples behave differently under Linux,
 Windows, or Mac OS X, they contain doctest directives in comments.
 
-Note: Some code samples reference the ctypes :class:`c_int` type. This type is
-an alias for the :class:`c_long` type on 32-bit systems.  So, you should not be
-confused if :class:`c_long` is printed if you would expect :class:`c_int` ---
-they are actually the same type.
-
+Note: Some code samples reference the ctypes :class:`c_int` type.  On platforms
+where ``sizeof(long double) == sizeof(double)`` it is an alias to
+:class:`c_double`.  So, you should not be confused if :class:`c_long` is
+printed if you would expect :class:`c_int` --- they are actually the same type.
 
 .. _ctypes-loading-dynamic-link-libraries: