https://github.com/python/cpython/commit/a00655b8775e00fb27644ac37c4e109d42dce5cd
commit: a00655b8775e00fb27644ac37c4e109d42dce5cd
branch: main
author: mdehoon <[email protected]>
committer: serhiy-storchaka <[email protected]>
date: 2025-10-13T13:29:42+03:00
summary:

gh-140001: Remove obsolete TCL_WIN_SOCKET macro (from Tcl 7.x) from _tkinter.c 
(GH-139998)

Co-authored-by: Michiel Jan Laurens de Hoon <[email protected]>

files:
M Modules/_tkinter.c

diff --git a/Modules/_tkinter.c b/Modules/_tkinter.c
index f0882191d3c3e8..c0ed8977d8fd6f 100644
--- a/Modules/_tkinter.c
+++ b/Modules/_tkinter.c
@@ -82,33 +82,10 @@ typedef int Tcl_Size;
 
 #ifdef HAVE_CREATEFILEHANDLER
 
-/* This bit is to ensure that TCL_UNIX_FD is defined and doesn't interfere
-   with the proper calculation of FHANDLETYPE == TCL_UNIX_FD below. */
-#ifndef TCL_UNIX_FD
-#  ifdef TCL_WIN_SOCKET
-#    define TCL_UNIX_FD (! TCL_WIN_SOCKET)
-#  else
-#    define TCL_UNIX_FD 1
-#  endif
-#endif
-
-/* Tcl_CreateFileHandler() changed several times; these macros deal with the
-   messiness.  In Tcl 8.0 and later, it is not available on Windows (and on
-   Unix, only because Jack added it back); when available on Windows, it only
-   applies to sockets. */
-
-#ifdef MS_WINDOWS
-#define FHANDLETYPE TCL_WIN_SOCKET
-#else
-#define FHANDLETYPE TCL_UNIX_FD
-#endif
-
 /* If Tcl can wait for a Unix file descriptor, define the EventHook() routine
    which uses this to handle Tcl events while the user is typing commands. */
 
-#if FHANDLETYPE == TCL_UNIX_FD
 #define WAIT_FOR_STDIN
-#endif
 
 #endif /* HAVE_CREATEFILEHANDLER */
 

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to