require uintptr_t to exist

This commit is contained in:
Benjamin Peterson 2016-09-06 13:33:56 -07:00
parent d982c8f51e
commit b9d9eeda2a
4 changed files with 0 additions and 77 deletions

View File

@ -23,10 +23,6 @@ Py_DEBUG
Meaning: Extra checks compiled in for debug mode.
Used in: Py_SAFE_DOWNCAST
HAVE_UINTPTR_T
Meaning: The C9X type uintptr_t is supported by the compiler
Used in: Py_uintptr_t
**************************************************************************/
/* typedefs for some C9X-defined synonyms for integral types.
@ -90,26 +86,9 @@ Used in: Py_uintptr_t
* without loss of information. Similarly for intptr_t, wrt a signed
* integral type.
*/
#ifdef HAVE_UINTPTR_T
typedef uintptr_t Py_uintptr_t;
typedef intptr_t Py_intptr_t;
#elif SIZEOF_VOID_P <= SIZEOF_INT
typedef unsigned int Py_uintptr_t;
typedef int Py_intptr_t;
#elif SIZEOF_VOID_P <= SIZEOF_LONG
typedef unsigned long Py_uintptr_t;
typedef long Py_intptr_t;
#elif SIZEOF_VOID_P <= SIZEOF_LONG_LONG
typedef unsigned long long Py_uintptr_t;
typedef long long Py_intptr_t;
#else
# error "Python needs a typedef for Py_uintptr_t in pyport.h."
#endif /* HAVE_UINTPTR_T */
/* Py_ssize_t is a signed integral type such that sizeof(Py_ssize_t) ==
* sizeof(size_t). C99 doesn't define such a thing directly (size_t is an
* unsigned integral type). See PEP 353 for details.

45
configure vendored
View File

@ -8471,51 +8471,6 @@ _ACEOF
fi
ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "#include <stdint.h>
#include <inttypes.h>
"
if test "x$ac_cv_type_uintptr_t" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_UINTPTR_T 1
_ACEOF
# The cast to long int works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
# This bug is HP SR number 8606223364.
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of uintptr_t" >&5
$as_echo_n "checking size of uintptr_t... " >&6; }
if ${ac_cv_sizeof_uintptr_t+:} false; then :
$as_echo_n "(cached) " >&6
else
if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (uintptr_t))" "ac_cv_sizeof_uintptr_t" "$ac_includes_default"; then :
else
if test "$ac_cv_type_uintptr_t" = yes; then
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error 77 "cannot compute sizeof (uintptr_t)
See \`config.log' for more details" "$LINENO" 5; }
else
ac_cv_sizeof_uintptr_t=0
fi
fi
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_uintptr_t" >&5
$as_echo "$ac_cv_sizeof_uintptr_t" >&6; }
cat >>confdefs.h <<_ACEOF
#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
_ACEOF
fi
# The cast to long int works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.

View File

@ -2101,11 +2101,6 @@ if test "$have_c99_bool" = yes ; then
AC_CHECK_SIZEOF(_Bool, 1)
fi
AC_CHECK_TYPES(uintptr_t,
[AC_CHECK_SIZEOF(uintptr_t, 4)],
[], [#include <stdint.h>
#include <inttypes.h>])
AC_CHECK_SIZEOF(off_t, [], [
#ifdef HAVE_SYS_TYPES_H
#include <sys/types.h>

View File

@ -1134,9 +1134,6 @@
/* Define this if you have tcl and TCL_UTF_MAX==6 */
#undef HAVE_UCS4_TCL
/* Define to 1 if the system has the type `uintptr_t'. */
#undef HAVE_UINTPTR_T
/* Define to 1 if you have the `uname' function. */
#undef HAVE_UNAME
@ -1311,9 +1308,6 @@
/* The size of `time_t', as computed by sizeof. */
#undef SIZEOF_TIME_T
/* The size of `uintptr_t', as computed by sizeof. */
#undef SIZEOF_UINTPTR_T
/* The size of `void *', as computed by sizeof. */
#undef SIZEOF_VOID_P