Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion Include/internal/pycore_condvar.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,9 @@
#define Py_HAVE_CONDVAR

/* include windows if it hasn't been done before */
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h> // CRITICAL_SECTION

/* options */
Expand Down
4 changes: 3 additions & 1 deletion Include/internal/pycore_semaphore.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
#include "pycore_pythread.h" // _POSIX_SEMAPHORES

#ifdef MS_WINDOWS
# define WIN32_LEAN_AND_MEAN
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h>
#elif defined(HAVE_PTHREAD_H)
# include <pthread.h>
Expand Down
4 changes: 3 additions & 1 deletion Modules/_interpchannelsmodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
#include "pycore_pystate.h" // _PyInterpreterState_GetIDObject()

#ifdef MS_WINDOWS
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h> // SwitchToThread()
#elif defined(HAVE_SCHED_H)
#include <sched.h> // sched_yield()
Expand Down
2 changes: 1 addition & 1 deletion Modules/_io/winconsoleio.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <stddef.h> /* For offsetof */

#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#include <fcntl.h>
Expand Down
4 changes: 3 additions & 1 deletion Python/lock.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
#include "pycore_time.h" // _PyTime_Add()

#ifdef MS_WINDOWS
# define WIN32_LEAN_AND_MEAN
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h> // SwitchToThread()
#elif defined(HAVE_SCHED_H)
# include <sched.h> // sched_yield()
Expand Down
4 changes: 3 additions & 1 deletion Python/sysmodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ Data members:
#endif

#ifdef MS_WINDOWS
# define WIN32_LEAN_AND_MEAN
# ifndef WIN32_LEAN_AND_MEAN
# define WIN32_LEAN_AND_MEAN
# endif
# include <windows.h>
#endif /* MS_WINDOWS */

Expand Down
Loading