Skip to content

Commit 52ae6f6

Browse files
committed
Fake bool API for Python 2.2.
1 parent 89feabc commit 52ae6f6

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Modules/_tkinter.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,11 @@ Copyright (C) 1994 Steen Lumholt.
4646
#define PyMODINIT_FUNC void
4747
#endif
4848

49+
#ifndef PyBool_Check
50+
#define PyBool_Check(o) 0
51+
#define PyBool_FromLong PyInt_FromLong
52+
#endif
53+
4954
/* Starting with Tcl 8.4, many APIs offer const-correctness. Unfortunately,
5055
making _tkinter correct for this API means to break earlier
5156
versions. USE_COMPAT_CONST allows to make _tkinter work with both 8.4 and

0 commit comments

Comments
 (0)