summaryrefslogtreecommitdiff
path: root/Modules/_struct.c
diff options
context:
space:
mode:
authorThomas Heller <theller@ctypes.org>2008-03-05 15:34:29 +0000
committerThomas Heller <theller@ctypes.org>2008-03-05 15:34:29 +0000
commit553cd2326c45752de212972d0ae88f877613e0a6 (patch)
tree4e8d25b907d14373c56c919555e9506f69f8b636 /Modules/_struct.c
parentd0a3c7160d8b2042b7abfb23f75745e467a51eca (diff)
downloadcpython-553cd2326c45752de212972d0ae88f877613e0a6.tar.gz
Issue 1872: Changed the struct module typecode from 't' to '?', for
compatibility with PEP3118.
Diffstat (limited to 'Modules/_struct.c')
-rw-r--r--Modules/_struct.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/_struct.c b/Modules/_struct.c
index 8e5420c7f7..e5fe211f29 100644
--- a/Modules/_struct.c
+++ b/Modules/_struct.c
@@ -799,7 +799,7 @@ static formatdef native_table[] = {
{'q', sizeof(PY_LONG_LONG), LONG_LONG_ALIGN, nu_longlong, np_longlong},
{'Q', sizeof(PY_LONG_LONG), LONG_LONG_ALIGN, nu_ulonglong,np_ulonglong},
#endif
- {'t', sizeof(BOOL_TYPE), BOOL_ALIGN, nu_bool, np_bool},
+ {'?', sizeof(BOOL_TYPE), BOOL_ALIGN, nu_bool, np_bool},
{'f', sizeof(float), FLOAT_ALIGN, nu_float, np_float},
{'d', sizeof(double), DOUBLE_ALIGN, nu_double, np_double},
{'P', sizeof(void *), VOID_P_ALIGN, nu_void_p, np_void_p},
@@ -1036,7 +1036,7 @@ static formatdef bigendian_table[] = {
{'L', 4, 0, bu_uint, bp_uint},
{'q', 8, 0, bu_longlong, bp_longlong},
{'Q', 8, 0, bu_ulonglong, bp_ulonglong},
- {'t', 1, 0, bu_bool, bp_bool},
+ {'?', 1, 0, bu_bool, bp_bool},
{'f', 4, 0, bu_float, bp_float},
{'d', 8, 0, bu_double, bp_double},
{0}
@@ -1255,7 +1255,7 @@ static formatdef lilendian_table[] = {
{'L', 4, 0, lu_uint, lp_uint},
{'q', 8, 0, lu_longlong, lp_longlong},
{'Q', 8, 0, lu_ulonglong, lp_ulonglong},
- {'t', 1, 0, bu_bool, bp_bool}, /* Std rep not endian dep,
+ {'?', 1, 0, bu_bool, bp_bool}, /* Std rep not endian dep,
but potentially different from native rep -- reuse bx_bool funcs. */
{'f', 4, 0, lu_float, lp_float},
{'d', 8, 0, lu_double, lp_double},