mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-05-22 21:32:31 +00:00
Improve Python tree-shaking
This commit is contained in:
parent
5bb2275788
commit
4f41f2184d
169 changed files with 4182 additions and 2411 deletions
2
third_party/python/Objects/obmalloc.c
vendored
2
third_party/python/Objects/obmalloc.c
vendored
|
@ -14,6 +14,7 @@
|
|||
#include "third_party/python/Include/pyerrors.h"
|
||||
#include "third_party/python/Include/pymacro.h"
|
||||
#include "third_party/python/Include/pymem.h"
|
||||
#include "third_party/python/Include/yoink.h"
|
||||
/* clang-format off */
|
||||
|
||||
#ifdef MODE_DBG
|
||||
|
@ -2198,6 +2199,7 @@ _PyObject_DebugDumpAddress(const void *p)
|
|||
|
||||
fflush(stderr);
|
||||
#ifdef USE_TRACEMALLOC
|
||||
PYTHON_YOINK("_tracemalloc");
|
||||
_PyMem_DumpTraceback(fileno(stderr), p);
|
||||
#endif
|
||||
}
|
||||
|
|
7
third_party/python/Objects/unicodeobject.c
vendored
7
third_party/python/Objects/unicodeobject.c
vendored
|
@ -43,6 +43,13 @@
|
|||
/* clang-format off */
|
||||
|
||||
PYTHON_PROVIDE("_string");
|
||||
PYTHON_PROVIDE("_string.__doc__");
|
||||
PYTHON_PROVIDE("_string.__loader__");
|
||||
PYTHON_PROVIDE("_string.__name__");
|
||||
PYTHON_PROVIDE("_string.__package__");
|
||||
PYTHON_PROVIDE("_string.__spec__");
|
||||
PYTHON_PROVIDE("_string.formatter_field_name_split");
|
||||
PYTHON_PROVIDE("_string.formatter_parser");
|
||||
|
||||
/*
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue