gh-104922: remove PY_SSIZE_T_CLEAN (#106315)

This commit is contained in:
Inada Naoki 2023-07-02 15:07:46 +09:00 committed by GitHub
parent 8571b271e7
commit d5bd32fb48
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
64 changed files with 0 additions and 90 deletions

View File

@ -7,7 +7,6 @@ Converted to C by Dmitry Vasiliev (dima at hlabs.spb.ru).
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallMethod()

View File

@ -1,7 +1,5 @@
/* _bz2 - Low-level Python interface to libbzip2. */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h" // PyMemberDef

View File

@ -30,7 +30,6 @@ Copyright (c) Corporation for National Research Initiatives.
------------------------------------------------------------------------ */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_codecs.h" // _PyCodec_Lookup()

View File

@ -101,7 +101,6 @@ bytes(cdata)
#ifndef Py_BUILD_CORE_BUILTIN
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
// windows.h must be included before pycore internal headers

View File

@ -104,8 +104,6 @@ static const char PyCursesVersion[] = "2.2";
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_long.h" // _PyLong_GetZero()
#include "pycore_structseq.h" // _PyStructSequence_NewType()

View File

@ -2,7 +2,6 @@
/* DBM module using dictionary interface */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include <sys/types.h>

View File

@ -11,8 +11,6 @@
*--------------------------------------------------------------------
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h" // PyMemberDef
#include "expat.h"

View File

@ -3,7 +3,6 @@
/* Author: Anthony Baxter, after dbmmodule.c */
/* Doc strings: Mitch Chapman */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "gdbm.h"

View File

@ -22,8 +22,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_hashtable.h"
#include "hashlib.h"

View File

@ -7,7 +7,6 @@
Mostly written by Amaury Forgeot d'Arc
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "_iomodule.h"
#include "pycore_pystate.h" // _PyInterpreterState_GET()

View File

@ -7,7 +7,6 @@
Written by Amaury Forgeot d'Arc and Antoine Pitrou
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallNoArgs()
#include "pycore_object.h"

View File

@ -1,6 +1,5 @@
/* Author: Daniel Stutzbach */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_fileutils.h" // _Py_BEGIN_SUPPRESS_IPH
#include "pycore_object.h" // _PyObject_GC_UNTRACK()

View File

@ -8,7 +8,6 @@
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallMethod()
#include "pycore_long.h" // _PyLong_GetOne()

View File

@ -1,4 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include <stddef.h> // offsetof()
#include "pycore_object.h"

View File

@ -6,7 +6,6 @@
Written by Amaury Forgeot d'Arc and Antoine Pitrou
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallMethod()
#include "pycore_codecs.h" // _PyCodecInfo_GetIncrementalDecoder()

View File

@ -6,7 +6,6 @@
Written by Steve Dower
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_fileutils.h" // _Py_BEGIN_SUPPRESS_IPH
#include "pycore_object.h" // _PyObject_GC_UNTRACK()

View File

@ -9,7 +9,6 @@ This software comes with no warranty. Use at your own risk.
******************************************************************/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_fileutils.h"

View File

@ -5,8 +5,6 @@
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h" // PyMemberDef

View File

@ -1,8 +1,6 @@
#ifndef MULTIPROCESSING_H
#define MULTIPROCESSING_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h"
#include "pythread.h"

View File

@ -2,8 +2,6 @@
posixshmem - A Python extension that provides shm_open() and shm_unlink()
*/
#define PY_SSIZE_T_CLEAN
#include <Python.h>
// for shm_open() and shm_unlink()

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_CONNECTION_H
#define PYSQLITE_CONNECTION_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pythread.h"
#include "structmember.h"

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_CURSOR_H
#define PYSQLITE_CURSOR_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "statement.h"

View File

@ -26,7 +26,6 @@
#ifndef PSYCOPG_MICROPROTOCOLS_H
#define PSYCOPG_MICROPROTOCOLS_H 1
#define PY_SSIZE_T_CLEAN
#include <Python.h>
/** exported functions **/

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_MODULE_H
#define PYSQLITE_MODULE_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#define LEGACY_TRANSACTION_CONTROL -1

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_ROW_H
#define PYSQLITE_ROW_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
typedef struct _Row

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_STATEMENT_H
#define PYSQLITE_STATEMENT_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "connection.h"

View File

@ -23,7 +23,6 @@
#ifndef PYSQLITE_UTIL_H
#define PYSQLITE_UTIL_H
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pythread.h"
#include "sqlite3.h"

View File

@ -38,8 +38,6 @@
static const char copyright[] =
" SRE 2.2.2 Copyright (c) 1997-2002 by Secret Labs AB ";
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_long.h" // _PyLong_GetZero()
#include "pycore_moduleobject.h" // _PyModule_GetState()

View File

@ -25,8 +25,6 @@
#endif
#define OPENSSL_NO_DEPRECATED 1
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_weakref.h" // _PyWeakref_GET_REF()

View File

@ -11,7 +11,6 @@
*
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#ifdef __cplusplus

View File

@ -7,8 +7,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_moduleobject.h" // _PyModule_GetState()
#include "structmember.h" // PyMemberDef

View File

@ -1,9 +1,6 @@
/* C Extension module to test all aspects of PEP-3118.
Written by Stefan Krah. */
#define PY_SSIZE_T_CLEAN
#include "Python.h"

View File

@ -1,5 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include "parts.h"
#include "clinic/float.c.h"

View File

@ -3,8 +3,6 @@
* APIs that parse and build arguments.
*/
#define PY_SSIZE_T_CLEAN
#include "parts.h"
static PyObject *

View File

@ -1,4 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include "parts.h"
#include <stddef.h> // for offsetof()

View File

@ -1,6 +1,5 @@
#include <stddef.h> // ptrdiff_t
#define PY_SSIZE_T_CLEAN
#include "parts.h"
static struct PyModuleDef *_testcapimodule = NULL; // set at initialization

View File

@ -17,8 +17,6 @@
/* Always enable assertions */
#undef NDEBUG
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "frameobject.h" // PyFrame_New
#include "marshal.h" // PyMarshal_WriteLongToFile

View File

@ -5,8 +5,6 @@
/* Always enable assertions */
#undef NDEBUG
#define PY_SSIZE_T_CLEAN
#include "Python.h"

View File

@ -9,8 +9,6 @@
/* Always enable assertions */
#undef NDEBUG
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "frameobject.h"
#include "interpreteridobject.h" // _PyInterpreterID_LookUp()

View File

@ -21,7 +21,6 @@ Copyright (C) 1994 Steen Lumholt.
*/
#define PY_SSIZE_T_CLEAN
#ifndef Py_BUILD_CORE_BUILTIN
# define Py_BUILD_CORE_MODULE 1
#endif

View File

@ -3,8 +3,6 @@
* DCE compatible Universally Unique Identifier library.
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#if defined(HAVE_UUID_H)
// AIX, FreeBSD, libuuid with pkgconf

View File

@ -1,4 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <stdlib.h>
#include <inttypes.h>

View File

@ -7,7 +7,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallMethod()
#include "pycore_moduleobject.h" // _PyModule_GetState()

View File

@ -57,8 +57,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_long.h" // _PyLong_DigitValue
#include "pycore_strhex.h" // _Py_strhex_bytes_with_sep()

View File

@ -7,7 +7,6 @@
#ifndef _CJKCODECS_H_
#define _CJKCODECS_H_
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "multibytecodec.h"

View File

@ -4,7 +4,6 @@
* Written by Hye-Shik Chang <perky@FreeBSD.org>
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h" // PyMemberDef
#include "multibytecodec.h"

View File

@ -1,8 +1,5 @@
/* fcntl module */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#ifdef HAVE_SYS_FILE_H

View File

@ -1,4 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallNoArgs()
#include "pycore_long.h" // _PyLong_GetZero()

View File

@ -22,7 +22,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include "pycore_bytesobject.h" // _PyBytes_Find()
#include "pycore_fileutils.h" // _Py_stat_struct

View File

@ -7,8 +7,6 @@
of the compiler used. Different compilers define their own feature
test macro, e.g. '_MSC_VER'. */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#ifdef __VXWORKS__

View File

@ -105,7 +105,6 @@ Local naming conventions:
# pragma weak inet_aton
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_fileutils.h" // _Py_set_inheritable()
#include "pycore_moduleobject.h" // _PyModule_GetState

View File

@ -16,8 +16,6 @@
# define Py_BUILD_CORE_MODULE 1
#endif
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_ucnhash.h" // _PyUnicode_Name_CAPI
#include "structmember.h" // PyMemberDef

View File

@ -3,8 +3,6 @@
/* Windows users: read Python's PCbuild\readme.txt */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "structmember.h" // PyMemberDef
#include "zlib.h"

View File

@ -1,6 +1,5 @@
/* PyByteArray (bytearray) implementation */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_abstract.h" // _PyIndex_Check()
#include "pycore_bytes_methods.h"

View File

@ -1,4 +1,3 @@
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_abstract.h" // _PyIndex_Check()
#include "pycore_bytes_methods.h"

View File

@ -1,7 +1,5 @@
/* bytes object implementation */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_abstract.h" // _PyIndex_Check()
#include "pycore_bytesobject.h" // _PyBytes_Find(), _PyBytes_Repeat()

View File

@ -4,7 +4,6 @@
* Thanks go to Tim Peters and Michael Hudson for debugging.
*/
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <stdbool.h>
#include "pycore_abstract.h" // _PyObject_RealIsSubclass()

View File

@ -1,6 +1,5 @@
/* File object implementation (what's left of it -- see io.py) */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallNoArgs()
#include "pycore_runtime.h" // _PyRuntime

View File

@ -1,6 +1,5 @@
/* PickleBuffer object implementation */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include <stddef.h>

View File

@ -38,7 +38,6 @@ OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_abstract.h" // _PyIndex_Check()
#include "pycore_atomic_funcs.h" // _Py_atomic_size_get()

View File

@ -12,7 +12,6 @@
*/
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_object.h" // _PyObject_Init()
#include "pycore_moduleobject.h"

View File

@ -1,7 +1,6 @@
#ifndef PEGEN_H
#define PEGEN_H
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <pycore_ast.h>
#include <pycore_token.h>

View File

@ -1,7 +1,6 @@
/* Tokenizer implementation */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallNoArgs()

View File

@ -6,8 +6,6 @@
Version 3 of this protocol properly supports circular links
and sharing. */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
#include "pycore_call.h" // _PyObject_CallNoArgs()
#include "pycore_code.h" // _PyCode_New()