Skip to content

Commit b8bcddd

Browse files
committed
Disable x87 control word for non-x86 targets
On msvc, x87 control word is only available on x86 target. Need to disable it for other targets to prevent compiling problems.
1 parent a0bb51e commit b8bcddd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Include/pyport.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,7 @@ extern "C" {
406406
#endif
407407

408408
/* get and set x87 control word for VisualStudio/x86 */
409-
#if defined(_MSC_VER) && !defined(_WIN64) /* x87 not supported in 64-bit */
409+
#if defined(_MSC_VER) && defined(_M_IX86) /* x87 only supported in x86 */
410410
#define HAVE_PY_SET_53BIT_PRECISION 1
411411
#define _Py_SET_53BIT_PRECISION_HEADER \
412412
unsigned int old_387controlword, new_387controlword, out_387controlword

0 commit comments

Comments
 (0)