| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 3f61c45 commit d625c5e
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -932,8 +932,8 @@ Build Changes | |||
| 932 | 932 | * Building CPython now requires a compiler with support for the C11 atomic | |
| 933 | 933 | library, GCC built-in atomic functions, or MSVC interlocked intrinsics. | |
| 934 | 934 | ||
| 935 | - * The ``_stat`` and ``_testimportmultiple`` C extensions are now built with the | ||
| 936 | - :ref:`limited C API <limited-c-api>`. | ||
| 935 | + * The ``errno``, ``_ctypes_test``, ``_stat`` and ``_testimportmultiple`` C | ||
| 936 | + extensions are now built with the :ref:`limited C API <limited-c-api>`. | ||
| 937 | 937 | (Contributed by Victor Stinner in :gh:`85283`.) | |
| 938 | 938 | ||
| 939 | 939 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,2 +1,3 @@ | |||
| 1 | - The ``_testimportmultiple`` C extension is now built with the :ref:`limited | ||
| 2 | - C API <limited-c-api>`. Patch by Victor Stinner. | ||
| 1 | + The ``errno``, ``_ctypes_test`` and ``_testimportmultiple`` C extensions are | ||
| 2 | + now built with the :ref:`limited C API <limited-c-api>`. Patch by Victor | ||
| 3 | + Stinner. | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,11 +1,12 @@ | |||
| 1 | + #define Py_LIMITED_API 0x03060000 | ||
| 2 | + | ||
| 1 | 3 | #include <Python.h> | |
| 2 | 4 | ||
| 5 | + #include <stdlib.h> // qsort() | ||
| 3 | 6 | #ifdef MS_WIN32 | |
| 4 | - #include <windows.h> | ||
| 7 | + # include <windows.h> | ||
| 5 | 8 | #endif | |
| 6 | 9 | ||
| 7 | - #include <stdlib.h> // qsort() | ||
| 8 | - | ||
| 9 | 10 | #define EXPORT(x) Py_EXPORTED_SYMBOL x | |
| 10 | 11 | ||
| 11 | 12 | /* some functions handy for testing */ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -4,7 +4,7 @@ | |||
| 4 | 4 | * foo, bar), only the first one is called the same as the compiled file. | |
| 5 | 5 | */ | |
| 6 | 6 | ||
| 7 | - #define Py_LIMITED_API 0x030d0000 | ||
| 7 | + #define Py_LIMITED_API 0x03020000 | ||
| 8 | 8 | ||
| 9 | 9 | #include <Python.h> | |
| 10 | 10 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,41 +1,44 @@ | |||
| 1 | - | ||
| 2 | 1 | /* Errno module */ | |
| 3 | 2 | ||
| 3 | + // Need PyModuleDef_Slot added to limited C API version 3.5 | ||
| 4 | + #define Py_LIMITED_API 0x03050000 | ||
| 5 | + | ||
| 4 | 6 | #include "Python.h" | |
| 5 | 7 | ||
| 6 | 8 | /* Windows socket errors (WSA*) */ | |
| 7 | 9 | #ifdef MS_WINDOWS | |
| 8 | - #ifndef WIN32_LEAN_AND_MEAN | ||
| 9 | - #define WIN32_LEAN_AND_MEAN | ||
| 10 | - #endif | ||
| 11 | - #include <windows.h> | ||
| 12 | - /* The following constants were added to errno.h in VS2010 but have | ||
| 13 | - preferred WSA equivalents. */ | ||
| 14 | - #undef EADDRINUSE | ||
| 15 | - #undef EADDRNOTAVAIL | ||
| 16 | - #undef EAFNOSUPPORT | ||
| 17 | - #undef EALREADY | ||
| 18 | - #undef ECONNABORTED | ||
| 19 | - #undef ECONNREFUSED | ||
| 20 | - #undef ECONNRESET | ||
| 21 | - #undef EDESTADDRREQ | ||
| 22 | - #undef EHOSTUNREACH | ||
| 23 | - #undef EINPROGRESS | ||
| 24 | - #undef EISCONN | ||
| 25 | - #undef ELOOP | ||
| 26 | - #undef EMSGSIZE | ||
| 27 | - #undef ENETDOWN | ||
| 28 | - #undef ENETRESET | ||
| 29 | - #undef ENETUNREACH | ||
| 30 | - #undef ENOBUFS | ||
| 31 | - #undef ENOPROTOOPT | ||
| 32 | - #undef ENOTCONN | ||
| 33 | - #undef ENOTSOCK | ||
| 34 | - #undef EOPNOTSUPP | ||
| 35 | - #undef EPROTONOSUPPORT | ||
| 36 | - #undef EPROTOTYPE | ||
| 37 | - #undef ETIMEDOUT | ||
| 38 | - #undef EWOULDBLOCK | ||
| 10 | + # ifndef WIN32_LEAN_AND_MEAN | ||
| 11 | + # define WIN32_LEAN_AND_MEAN | ||
| 12 | + # endif | ||
| 13 | + # include <windows.h> | ||
| 14 | + | ||
| 15 | + // The following constants were added to errno.h in VS2010 but have | ||
| 16 | + // preferred WSA equivalents. | ||
| 17 | + # undef EADDRINUSE | ||
| 18 | + # undef EADDRNOTAVAIL | ||
| 19 | + # undef EAFNOSUPPORT | ||
| 20 | + # undef EALREADY | ||
| 21 | + # undef ECONNABORTED | ||
| 22 | + # undef ECONNREFUSED | ||
| 23 | + # undef ECONNRESET | ||
| 24 | + # undef EDESTADDRREQ | ||
| 25 | + # undef EHOSTUNREACH | ||
| 26 | + # undef EINPROGRESS | ||
| 27 | + # undef EISCONN | ||
| 28 | + # undef ELOOP | ||
| 29 | + # undef EMSGSIZE | ||
| 30 | + # undef ENETDOWN | ||
| 31 | + # undef ENETRESET | ||
| 32 | + # undef ENETUNREACH | ||
| 33 | + # undef ENOBUFS | ||
| 34 | + # undef ENOPROTOOPT | ||
| 35 | + # undef ENOTCONN | ||
| 36 | + # undef ENOTSOCK | ||
| 37 | + # undef EOPNOTSUPP | ||
| 38 | + # undef EPROTONOSUPPORT | ||
| 39 | + # undef EPROTOTYPE | ||
| 40 | + # undef ETIMEDOUT | ||
| 41 | + # undef EWOULDBLOCK | ||
| 39 | 42 | #endif | |
| 40 | 43 | ||
| 41 | 44 | /* | |
| Back | FazBrowse Home | New Git URL |
0 commit comments