.
diff --git generic/tclCompile.h generic/tclCompile.h
index 245a891105..4e749390f4 100644
--- generic/tclCompile.h
+++ generic/tclCompile.h
@@ -1481,22 +1481,7 @@ TclUpdateStackReqs(
* unsigned int TclGetUInt4AtPtr(unsigned char *p);
*/
-/*
- * The TclGetInt1AtPtr macro is tricky because we want to do sign extension on
- * the 1-byte value. Unfortunately the "char" type isn't signed on all
- * platforms so sign-extension doesn't always happen automatically. Sometimes
- * we can explicitly declare the pointer to be signed, but other times we have
- * to explicitly sign-extend the value in software.
- */
-
-#ifndef __CHAR_UNSIGNED__
-# define TclGetInt1AtPtr(p) ((int) *((char *) p))
-#elif defined(HAVE_SIGNED_CHAR)
-# define TclGetInt1AtPtr(p) ((int) *((signed char *) p))
-#else
-# define TclGetInt1AtPtr(p) \
- ((int) ((*((char *) p)) | ((*(p) & 0200) ? (-256) : 0)))
-#endif
+#define TclGetInt1AtPtr(p) ((int) *((signed char *) p))
#define TclGetInt4AtPtr(p) \
((int) ((TclGetUInt1AtPtr(p) << 24) | \
diff --git unix/configure unix/configure
index ddd8d62992..b1a510a90e 100755
--- unix/configure
+++ unix/configure
@@ -10408,88 +10408,6 @@ printf '%s\n' "#define GETTOD_NOT_DECLARED 1" >>confdefs.h
fi
-#--------------------------------------------------------------------
-# The following code checks to see whether it is possible to get
-# signed chars on this platform. This is needed in order to
-# properly generate sign-extended ints from character values.
-#--------------------------------------------------------------------
-
-{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
-printf %s "checking whether char is unsigned... " >&6; }
-if test ${ac_cv_c_char_unsigned+y}
-then :
- printf %s "(cached) " >&6
-else case e in #(
- e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-int
-main (void)
-{
-static int test_array [1 - 2 * !(((char) -1) < 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"
-then :
- ac_cv_c_char_unsigned=no
-else case e in #(
- e) ac_cv_c_char_unsigned=yes ;;
-esac
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
-esac
-fi
-{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
-printf '%s\n' "$ac_cv_c_char_unsigned" >&6; }
-if test $ac_cv_c_char_unsigned = yes; then
- printf '%s\n' "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
-
-fi
-
-{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking signed char declarations" >&5
-printf %s "checking signed char declarations... " >&6; }
-if test ${tcl_cv_char_signed+y}
-then :
- printf %s "(cached) " >&6
-else case e in #(
- e)
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main (void)
-{
-
- signed char *p;
- p = 0;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"
-then :
- tcl_cv_char_signed=yes
-else case e in #(
- e) tcl_cv_char_signed=no ;;
-esac
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
-esac
-fi
-{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_char_signed" >&5
-printf '%s\n' "$tcl_cv_char_signed" >&6; }
-if test $tcl_cv_char_signed = yes; then
-
-printf '%s\n' "#define HAVE_SIGNED_CHAR 1" >>confdefs.h
-
-fi
-
#--------------------------------------------------------------------
# Does putenv() copy or not? We need to know to avoid memory leaks.
#--------------------------------------------------------------------
diff --git unix/configure.ac unix/configure.ac
index db735db0a3..14d7f0a03f 100644
--- unix/configure.ac
+++ unix/configure.ac
@@ -459,22 +459,6 @@ if test $tcl_cv_grep_gettimeofday = missing ; then
AC_DEFINE(GETTOD_NOT_DECLARED, 1, [Is gettimeofday() actually declared in <sys/time.h>?])
fi
-#--------------------------------------------------------------------
-# The following code checks to see whether it is possible to get
-# signed chars on this platform. This is needed in order to
-# properly generate sign-extended ints from character values.
-#--------------------------------------------------------------------
-
-AC_C_CHAR_UNSIGNED
-AC_CACHE_CHECK([signed char declarations], tcl_cv_char_signed, [
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[
- signed char *p;
- p = 0;
- ]])],[tcl_cv_char_signed=yes],[tcl_cv_char_signed=no])])
-if test $tcl_cv_char_signed = yes; then
- AC_DEFINE(HAVE_SIGNED_CHAR, 1, [Are characters signed?])
-fi
-
#--------------------------------------------------------------------
# Does putenv() copy or not? We need to know to avoid memory leaks.
#--------------------------------------------------------------------
diff --git unix/tclConfig.h.in unix/tclConfig.h.in
index be7504879e..ef9afebc88 100644
--- unix/tclConfig.h.in
+++ unix/tclConfig.h.in
@@ -189,9 +189,6 @@
/* Does putenv() copy strings or incorporate them by reference? */
#undef HAVE_PUTENV_THAT_COPIES
-/* Are characters signed? */
-#undef HAVE_SIGNED_CHAR
-
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
@@ -485,12 +482,6 @@
/* Do we want to use the XOPEN network library? */
#undef _XOPEN_SOURCE_EXTENDED
-/* Define to 1 if type 'char' is unsigned and your compiler does not
- predefine this macro. */
-#ifndef __CHAR_UNSIGNED__
-# undef __CHAR_UNSIGNED__
-#endif
-
/* Define as 'int' if <sys/types.h> doesn't define. */
#undef gid_t