Reduce header complexity

- Remove most __ASSEMBLER__ __LINKER__ ifdefs
- Rename libc/intrin/bits.h to libc/serialize.h
- Block pthread cancelation in fchmodat() polyfill
- Remove `clang-format off` statements in third_party
This commit is contained in:
Justine Tunney 2023-11-28 14:24:28 -08:00
parent 96f979dfc5
commit fa20edc44d
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
3057 changed files with 410 additions and 4398 deletions

View file

@ -1,9 +1,7 @@
#ifndef COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_PYTHON_AST_H_
#define COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_PYTHON_AST_H_
#include "third_party/python/Include/asdl.h"
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
/* clang-format off */
/* File automatically generated by Parser/asdl_c.py. */
typedef struct _mod *mod_ty;
@ -641,5 +639,4 @@ mod_ty PyAST_obj2mod(PyObject* ast, PyArena* arena, int mode);
int PyAST_Check(PyObject* obj);
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_PYTHON_AST_H_ */

View file

@ -1,6 +1,5 @@
#ifndef Py_PYTHON_H
#define Py_PYTHON_H
/* clang-format off */
/*
* PYTHON DIAMOND DEPENDENCY HEADER

View file

@ -3,7 +3,6 @@
#define Py_ACCU_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#undef small /* defined by some Windows headers */

View file

@ -2,7 +2,6 @@
#define Py_ASDL_H
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyarena.h"
/* clang-format off */
typedef PyObject * identifier;
typedef PyObject * string;

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/node.h"
#include "third_party/python/Include/pythonrun.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern int foo;
int PyAST_Validate(mod_ty);

View file

@ -2,7 +2,6 @@
#define Py_BITSET_H
#include "third_party/python/Include/pgenheaders.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#define BYTE char

View file

@ -2,7 +2,6 @@
#define Py_BLTINMODULE_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern PyTypeObject PyFilter_Type;
extern PyTypeObject PyMap_Type;

View file

@ -2,7 +2,6 @@
#define Py_BOOLOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern PyTypeObject PyBool_Type;

View file

@ -3,7 +3,6 @@
#include "libc/assert.h"
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Type PyByteArrayObject represents a mutable array of bytes.
* The Python API is that of a sequence;

View file

@ -3,7 +3,6 @@
#define Py_BYTES_CTYPE_H
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pymacro.h"
/* clang-format off */
/*
* The internal implementation behind PyBytes (bytes) and PyByteArray (bytearray)

View file

@ -2,7 +2,6 @@
#define Py_BYTESOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/*
Type PyBytesObject represents a character string. An extra zero byte is

View file

@ -3,7 +3,6 @@
#define Py_CELLOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct {
PyObject_HEAD

View file

@ -8,7 +8,6 @@
#include "third_party/python/Include/pystate.h"
#include "third_party/python/Include/pythonrun.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Interface to random parts in ceval.c */

View file

@ -3,7 +3,6 @@
#define Py_CLASSOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct {
PyObject_HEAD

View file

@ -2,7 +2,6 @@
#define Py_CODECREGISTRY_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* ------------------------------------------------------------------------

View file

@ -10,7 +10,6 @@ COSMOPOLITAN_C_START_
#define Py_eval_input 258
#ifndef Py_LIMITED_API
/* clang-format off */
/* Public interface */
struct _node; /* Declare the existence of this type */

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/unicodeobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
typedef struct {

View file

@ -3,7 +3,6 @@
#define DATETIME_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#pragma GCC diagnostic ignored "-Wunused-variable"
/* Fields are packed into successive bytes, each viewed as unsigned and

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef PyObject *(*getter)(PyObject *, void *);
typedef int (*setter)(PyObject *, PyObject *, void *);

View file

@ -2,7 +2,6 @@
#define Py_DICTOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Dictionary object type -- mapping from hashable object to object */

View file

@ -1,7 +1,6 @@
#ifndef Py_LIMITED_API
#ifndef PY_NO_SHORT_FLOAT_REPR
COSMOPOLITAN_C_START_
/* clang-format off */
double _Py_dg_strtod(const char *str, char **ptr);
char * _Py_dg_dtoa(double d, int mode, int ndigits,

View file

@ -4,7 +4,6 @@
#define DYNAMIC_ANNOTATIONS_ENABLED 0
#endif
#if DYNAMIC_ANNOTATIONS_ENABLED != 0
/* clang-format off */
/* Copyright (c) 2008-2009, Google Inc.
* All rights reserved.

View file

@ -2,7 +2,6 @@
#define Py_ENUMOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern PyTypeObject PyEnum_Type;
extern PyTypeObject PyReversed_Type;

View file

@ -1,7 +1,6 @@
#ifndef Py_ERRCODE_H
#define Py_ERRCODE_H
COSMOPOLITAN_C_START_
/* clang-format off */
/* Error codes passed around between file input, tokenizer, parser and

View file

@ -2,7 +2,6 @@
#define Py_EVAL_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
PyObject * PyEval_EvalCode(PyObject *, PyObject *, PyObject *);

View file

@ -6,7 +6,6 @@
#include "third_party/python/Include/bytesobject.h"
#include "third_party/python/Include/pyerrors.h"
#include "third_party/python/Include/unicodeobject.h"
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
static void EzPrint(PyObject *x, const char *s) {
@ -34,5 +33,4 @@ static void EzPrint(PyObject *x, const char *s) {
#define EZPRINT(x) EzPrint(x, #x)
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_EZPRINT_H_ */

View file

@ -2,7 +2,6 @@
#define Py_FILEOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#define PY_STDIOTEXTMODE "b"

View file

@ -3,7 +3,6 @@
#include "libc/calls/struct/stat.h"
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000
wchar_t * Py_DecodeLocale(

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/unicodeobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
typedef struct {

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pystate.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct {
int b_type; /* what kind of block this is */

View file

@ -3,7 +3,6 @@
#define Py_FUNCOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Function objects and code objects should not be confused with each other:
*

View file

@ -3,7 +3,6 @@
#define Py_GENOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
struct _frame; /* Avoid including frameobject.h */

View file

@ -1,4 +1,3 @@
/* clang-format off */
/* Generated by Parser/pgen */
#define single_input 256

View file

@ -3,7 +3,6 @@
#include "libc/stdio/stdio.h"
#include "third_party/python/Include/bitset.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* A label of an arc */
typedef struct {

View file

@ -2,7 +2,6 @@
#define Py_IMPORT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
void _PyImportZip_Init(void);

View file

@ -1,7 +1,6 @@
#ifndef Py_INTRCHECK_H
#define Py_INTRCHECK_H
COSMOPOLITAN_C_START_
/* clang-format off */
int PyOS_InterruptOccurred(void);
void PyOS_InitInterrupts(void);

View file

@ -2,7 +2,6 @@
#define Py_ITEROBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern PyTypeObject PySeqIter_Type;
extern PyTypeObject PyCallIter_Type;

View file

@ -2,7 +2,6 @@
#define Py_LISTOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* List object interface

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* This is published for the benefit of "friends" marshal.c and _decimal.c. */

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/unicodeobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Long (arbitrary precision) integer object interface */

View file

@ -2,7 +2,6 @@
#define Py_MARSHAL_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#define Py_MARSHAL_VERSION 4

View file

@ -2,7 +2,6 @@
#define Py_MEMORYOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
extern PyTypeObject _PyManagedBuffer_Type;

View file

@ -1,7 +1,6 @@
#ifndef Py_METAGRAMMAR_H
#define Py_METAGRAMMAR_H
COSMOPOLITAN_C_START_
/* clang-format off */
#define MSTART 256
#define RULE 257

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* This is about the type 'builtin_function_or_method',
not Python methods in user-defined classes. See classobject.h

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/object.h"
#pragma GCC diagnostic ignored "-Wredundant-decls"
COSMOPOLITAN_C_START_
/* clang-format off */
/* If PY_SSIZE_T_CLEAN is defined, each functions treats #-specifier
to mean Py_ssize_t */

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/methodobject.h"
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
extern PyTypeObject PyModule_Type;

View file

@ -2,7 +2,6 @@
#define NAMESPACEOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
extern PyTypeObject _PyNamespace_Type;

View file

@ -2,7 +2,6 @@
#define Py_NODE_H
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct _node {
short n_type;

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/op.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Object and type object interface */

View file

@ -7,7 +7,6 @@
#include "third_party/python/Include/pymem.h"
#include "third_party/python/Include/tupleobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
void * PyObject_Malloc(size_t);
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000

View file

@ -2,7 +2,6 @@
#define Py_ODICTOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* OrderedDict */
/* This API is optional and mostly redundant. */

View file

@ -2,7 +2,6 @@
#define Py_OPCODE_H
#include "third_party/python/Include/op.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Auto-generated by Tools/scripts/generate_opcode_h.py */
/* Instruction opcodes for compiled code */

View file

@ -2,7 +2,6 @@
#define Py_OSMODULE_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03060000
PyObject * PyOS_FSPath(PyObject *path);

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/node.h"
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct {
int error;

View file

@ -1,4 +1,3 @@
/* clang-format off */
/* Python version identification scheme.

View file

@ -2,7 +2,6 @@
#define Py_PGEN_H
#include "third_party/python/Include/grammar.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Parser generator interface */

View file

@ -2,7 +2,6 @@
#define Py_PGENHEADERS_H
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
void PySys_WriteStdout(const char *format, ...)
Py_GCC_ATTRIBUTE((format(printf, 1, 2)));

View file

@ -1,7 +1,6 @@
#ifndef Py_CURSES_H
#define Py_CURSES_H
#include "third_party/python/Include/object.h"
/* clang-format off */
#if !defined(HAVE_CURSES_IS_PAD) && defined(WINDOW_HAS_FLAGS)
/* The following definition is necessary for ncurses 5.7; without it,

View file

@ -3,7 +3,6 @@
#define Py_PYARENA_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct _arena PyArena;

View file

@ -3,7 +3,6 @@
#include "libc/assert.h"
#include "third_party/python/Include/dynamic_annotations.h"
#include "third_party/python/pyconfig.h"
/* clang-format off */
/* This is modeled after the atomics interface from C1x, according to
* the draft at

View file

@ -2,7 +2,6 @@
#define Py_CAPSULE_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Capsule objects let you wrap a C "void *" pointer in a Python
object. They're a way of passing data through the Python interpreter

View file

@ -2,7 +2,6 @@
#ifndef Py_PYDEBUG_H
#define Py_PYDEBUG_H
COSMOPOLITAN_C_START_
/* clang-format off */
#include "libc/runtime/runtime.h"
/* These global variable are defined in pylifecycle.c */

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/unicodeobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
/* PyException_HEAD defines the initial segment of every exception class. */

View file

@ -2,9 +2,7 @@
#define COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_PYEXPAT_H_
#include "third_party/python/Modules/expat/expat.h"
#include "third_party/python/Modules/expat/expat_external.h"
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
/* clang-format off */
#define PyExpat_CAPI_MAGIC "pyexpat.expat_CAPI 1.1"
#define PyExpat_CAPSULE_NAME "pyexpat.expat_CAPI"
@ -58,5 +56,4 @@ struct PyExpat_CAPI
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_THIRD_PARTY_PYTHON_INCLUDE_PYEXPAT_H_ */

View file

@ -1,7 +1,6 @@
#ifndef Py_PYFPE_H
#define Py_PYFPE_H
COSMOPOLITAN_C_START_
/* clang-format off */
#ifdef WANT_SIGFPE_HANDLER
extern jmp_buf PyFPE_jbuf;
extern int PyFPE_counter;

View file

@ -1,7 +1,6 @@
#ifndef Py_PYGETOPT_H
#define Py_PYGETOPT_H
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
extern int _PyOS_opterr;

View file

@ -2,7 +2,6 @@
#define Py_HASH_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Helpers for hash functions */
#ifndef Py_LIMITED_API

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pystate.h"
COSMOPOLITAN_C_START_
/* clang-format off */
void Py_SetProgramName(wchar_t *);
wchar_t * Py_GetProgramName(void);

View file

@ -1,6 +1,5 @@
#ifndef Py_PYMACRO_H
#define Py_PYMACRO_H
/* clang-format off */
/* Minimum value between x and y */
#define Py_MIN(x, y) (((x) > (y)) ? (y) : (x))

View file

@ -2,7 +2,6 @@
#define Py_PYMATH_H
#include "libc/math.h"
#include "third_party/python/pyconfig.h"
/* clang-format off */
/**************************************************************************
Symbols and macros to supply platform-independent interfaces to mathematical

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Debug-mode build with pymalloc implies PYMALLOC_DEBUG.
* PYMALLOC_DEBUG is in error if pymalloc is not in use.

View file

@ -3,7 +3,6 @@
#include "libc/limits.h"
#include "third_party/python/Include/pymath.h"
#include "third_party/python/pyconfig.h"
/* clang-format off */
#define HAVE_LONG_LONG 1
#define PY_LONG_LONG long long

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyatomic.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* This limitation is for performance and simplicity. If needed it can be
removed (with effort). */

View file

@ -2,7 +2,6 @@
#define Py_STRCMP_H
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
int PyOS_mystrnicmp(const char *, const char *, Py_ssize_t);
int PyOS_mystricmp(const char *, const char *);

View file

@ -2,7 +2,6 @@
#define Py_STRHEX_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API
/* Returns a str() containing the hex representation of argbuf. */

View file

@ -2,7 +2,6 @@
#define Py_STRTOD_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
double PyOS_string_to_double(const char *str,
char **endptr,

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/pyarena.h"
#include "third_party/python/Include/pystate.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#define PyCF_MASK (CO_FUTURE_DIVISION | CO_FUTURE_ABSOLUTE_IMPORT | \
CO_FUTURE_WITH_STATEMENT | CO_FUTURE_PRINT_FUNCTION | \

View file

@ -2,7 +2,6 @@
#define Py_PYTHREAD_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef void *PyThread_type_lock;
typedef void *PyThread_type_sema;

View file

@ -2,7 +2,6 @@
#define Py_RANGEOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/*
A range object represents an integer range. This is an immutable object;

View file

@ -2,7 +2,6 @@
#define Py_SETOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#ifndef Py_LIMITED_API

View file

@ -2,7 +2,6 @@
#define Py_SLICEOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* The unique ellipsis object "..." */

View file

@ -2,7 +2,6 @@
#define Py_STRUCTMEMBER_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* Interface to map C struct members to Python object attributes */

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/tupleobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct PyStructSequence_Field {
char *name;

View file

@ -5,7 +5,6 @@
#include "third_party/python/Include/compile.h"
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef enum _block_type { FunctionBlock, ClassBlock, ModuleBlock }
_Py_block_ty;

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pyport.h"
COSMOPOLITAN_C_START_
/* clang-format off */
PyObject * PySys_GetObject(const char *);
int PySys_SetObject(const char *, PyObject *);

View file

@ -2,7 +2,6 @@
#ifndef Py_TOKEN_H
#define Py_TOKEN_H
COSMOPOLITAN_C_START_
/* clang-format off */
#undef TILDE /* Prevent clash of our definition with system macro. Ex AIX, ioctl.h */

View file

@ -3,7 +3,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pystate.h"
COSMOPOLITAN_C_START_
/* clang-format off */
struct _frame;

View file

@ -2,7 +2,6 @@
#define Py_TUPLEOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/*
Another generally useful object type is a tuple of object pointers.

View file

@ -1,4 +1,3 @@
/* clang-format off */
/* Do not renumber the file; these numbers are part of the stable ABI. */
/* Disabled, see #10181 */
#undef Py_bf_getbuffer

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/unicodeobject.h"
COSMOPOLITAN_C_START_
/* clang-format off */
/* revised ucnhash CAPI interface (exported through a "wrapper") */

View file

@ -4,7 +4,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/pyconfig.h"
COSMOPOLITAN_C_START_
/* clang-format off */
#define Py_USING_UNICODE

View file

@ -2,7 +2,6 @@
#define Py_WEAKREFOBJECT_H
#include "third_party/python/Include/object.h"
COSMOPOLITAN_C_START_
/* clang-format off */
typedef struct _PyWeakReference PyWeakReference;

View file

@ -21,7 +21,6 @@
#include "third_party/python/Include/structmember.h"
#include "third_party/python/Include/traceback.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_asyncio");
PYTHON_PROVIDE("_asyncio.Future");

View file

@ -13,7 +13,6 @@
#include "third_party/python/Include/pyerrors.h"
#include "third_party/python/Include/pymacro.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_bisect");
PYTHON_PROVIDE("_bisect.bisect");

View file

@ -18,7 +18,6 @@
#include "third_party/python/Include/pythread.h"
#include "third_party/python/Include/structmember.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_bz2");
PYTHON_PROVIDE("_bz2.BZ2Compressor");

View file

@ -16,7 +16,6 @@
#include "third_party/python/Include/unicodeobject.h"
#include "third_party/python/Include/warnings.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_codecs");
PYTHON_PROVIDE("_codecs._forget_codec");

View file

@ -15,7 +15,6 @@
#include "third_party/python/Include/pymem.h"
#include "third_party/python/Include/structmember.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_collections");
PYTHON_PROVIDE("_collections.OrderedDict");

View file

@ -8,7 +8,6 @@
#include "third_party/python/Include/object.h"
#include "third_party/python/Include/pymacro.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_crypt");
PYTHON_PROVIDE("_crypt.crypt");

View file

@ -18,7 +18,6 @@
#include "third_party/python/Include/structmember.h"
#include "third_party/python/Include/unicodeobject.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_csv");
PYTHON_PROVIDE("_csv.Dialect");

View file

@ -25,7 +25,6 @@
#include "third_party/python/Include/structmember.h"
#include "third_party/python/Include/tupleobject.h"
#include "third_party/python/Include/yoink.h"
/* clang-format off */
PYTHON_PROVIDE("_datetime");
PYTHON_PROVIDE("_datetime.MAXYEAR");

Some files were not shown because too many files have changed in this diff Show more