Skip to content

Commit 7fb93a9

Browse files
author
Erlend E. Aasland
committed
Include pycore_object late to avoid conflict with windows.h
1 parent 70dcae3 commit 7fb93a9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Modules/_winapi.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@
3636

3737
#include "Python.h"
3838
#include "pycore_moduleobject.h" // _PyModule_GetState()
39-
#include "pycore_object.h" // _PyType_DisabledNew()
4039
#include "structmember.h" // PyMemberDef
4140

4241

@@ -45,6 +44,9 @@
4544
#include <crtdbg.h>
4645
#include "winreparse.h"
4746

47+
// Include pycore_object.h to avoid conflict with windows.h
48+
#include "pycore_object.h" // _PyType_DisabledNew()
49+
4850
#if defined(MS_WIN32) && !defined(MS_WIN64)
4951
#define HANDLE_TO_PYNUM(handle) \
5052
PyLong_FromUnsignedLong((unsigned long) handle)

0 commit comments

Comments
 (0)