diff options
author | Nicholas Sim <nsim+github@posteo.net> | 2021-02-16 12:04:38 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-16 12:04:38 (GMT) |
commit | 17dbd4078b68db8954df6b5cdc40b786bc4ad7af (patch) | |
tree | e48e54740a78deac7d08fb72ad2a1fb15fce8cc1 | |
parent | 871eb4237b9be95263ca13ba8856e78344eb9eba (diff) | |
download | cpython-17dbd4078b68db8954df6b5cdc40b786bc4ad7af.zip cpython-17dbd4078b68db8954df6b5cdc40b786bc4ad7af.tar.gz cpython-17dbd4078b68db8954df6b5cdc40b786bc4ad7af.tar.bz2 |
bpo-35134, Include: Move pytime.h to cpython/pytime.h (GH-23988)
This change is backward compatible since C extension modules
must not include "pytime.h" directly, but only include "Python.h".
-rw-r--r-- | Include/Python.h | 2 | ||||
-rw-r--r-- | Include/cpython/pytime.h (renamed from Include/pytime.h) | 3 | ||||
-rw-r--r-- | Makefile.pre.in | 2 | ||||
-rw-r--r-- | Modules/gcmodule.c | 1 | ||||
-rw-r--r-- | PCbuild/pythoncore.vcxproj | 2 | ||||
-rw-r--r-- | PCbuild/pythoncore.vcxproj.filters | 6 |
6 files changed, 6 insertions, 10 deletions
diff --git a/Include/Python.h b/Include/Python.h index 57f71d4..76ead9e 100644 --- a/Include/Python.h +++ b/Include/Python.h @@ -82,7 +82,6 @@ #error "PYMALLOC_DEBUG requires WITH_PYMALLOC" #endif #include "pymath.h" -#include "pytime.h" #include "pymem.h" #include "object.h" @@ -128,6 +127,7 @@ #include "structseq.h" #include "namespaceobject.h" #include "picklebufobject.h" +#include "cpython/pytime.h" #include "codecs.h" #include "pyerrors.h" diff --git a/Include/pytime.h b/Include/cpython/pytime.h index 944170f..56607d1 100644 --- a/Include/pytime.h +++ b/Include/cpython/pytime.h @@ -2,9 +2,6 @@ #ifndef Py_PYTIME_H #define Py_PYTIME_H -#include "pyconfig.h" /* include for defines */ -#include "object.h" - /************************************************************************** Symbols and macros to supply platform-independent interfaces to time related functions and constants diff --git a/Makefile.pre.in b/Makefile.pre.in index 0b22bdd..0d9fdc7 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -1075,7 +1075,6 @@ PYTHON_HEADERS= \ $(srcdir)/Include/pystrtod.h \ $(srcdir)/Include/pythonrun.h \ $(srcdir)/Include/pythread.h \ - $(srcdir)/Include/pytime.h \ $(srcdir)/Include/rangeobject.h \ $(srcdir)/Include/setobject.h \ $(srcdir)/Include/sliceobject.h \ @@ -1116,6 +1115,7 @@ PYTHON_HEADERS= \ $(srcdir)/Include/cpython/pymem.h \ $(srcdir)/Include/cpython/pystate.h \ $(srcdir)/Include/cpython/pythonrun.h \ + $(srcdir)/Include/cpython/pytime.h \ $(srcdir)/Include/cpython/sysmodule.h \ $(srcdir)/Include/cpython/traceback.h \ $(srcdir)/Include/cpython/tupleobject.h \ diff --git a/Modules/gcmodule.c b/Modules/gcmodule.c index fdbba6a..f0d5699 100644 --- a/Modules/gcmodule.c +++ b/Modules/gcmodule.c @@ -31,7 +31,6 @@ #include "pycore_pyerrors.h" #include "pycore_pystate.h" // _PyThreadState_GET() #include "pydtrace.h" -#include "pytime.h" // _PyTime_GetMonotonicClock() typedef struct _gc_runtime_state GCState; diff --git a/PCbuild/pythoncore.vcxproj b/PCbuild/pythoncore.vcxproj index f172f2a..711a68f 100644 --- a/PCbuild/pythoncore.vcxproj +++ b/PCbuild/pythoncore.vcxproj @@ -147,6 +147,7 @@ <ClInclude Include="..\Include\cpython\pymem.h" /> <ClInclude Include="..\Include\cpython\pystate.h" /> <ClInclude Include="..\Include\cpython\pythonrun.h" /> + <ClInclude Include="..\Include\cpython\pytime.h" /> <ClInclude Include="..\Include\cpython\sysmodule.h" /> <ClInclude Include="..\Include\cpython\traceback.h" /> <ClInclude Include="..\Include\cpython\tupleobject.h" /> @@ -245,7 +246,6 @@ <ClInclude Include="..\Include\pystrtod.h" /> <ClInclude Include="..\Include\pythonrun.h" /> <ClInclude Include="..\Include\pythread.h" /> - <ClInclude Include="..\Include\pytime.h" /> <ClInclude Include="..\Include\rangeobject.h" /> <ClInclude Include="..\Include\setobject.h" /> <ClInclude Include="..\Include\sliceobject.h" /> diff --git a/PCbuild/pythoncore.vcxproj.filters b/PCbuild/pythoncore.vcxproj.filters index 3bafdb8..ab82642 100644 --- a/PCbuild/pythoncore.vcxproj.filters +++ b/PCbuild/pythoncore.vcxproj.filters @@ -204,9 +204,6 @@ <ClInclude Include="..\Include\pymath.h"> <Filter>Include</Filter> </ClInclude> - <ClInclude Include="..\Include\pytime.h"> - <Filter>Include</Filter> - </ClInclude> <ClInclude Include="..\Include\pymacro.h"> <Filter>Include</Filter> </ClInclude> @@ -450,6 +447,9 @@ <ClInclude Include="..\Include\cpython\pylifecycle.h"> <Filter>Include\cpython</Filter> </ClInclude> + <ClInclude Include="..\Include\cpython\pytime.h"> + <Filter>Include\cpython</Filter> + </ClInclude> <ClInclude Include="..\Include\cpython\tupleobject.h"> <Filter>Include\cpython</Filter> </ClInclude> |