@@ -31,10 +31,23 @@ #import "macros.h" #import "autorelease.h" #import "block.h" +/* + * Some versions of MinGW require to be included before + * . Do this here to make sure this is always done in the correct + * order, even if another header includes just . + */ +#ifdef __MINGW32__ +# include <_mingw.h> +# ifdef __MINGW64_VERSION_MAJOR +# include +# include +# endif +#endif + OF_ASSUME_NONNULL_BEGIN /*! @file */ /*!