Trent Mick:
Use "win32" for sys.platform on Win64 instead of "win32" because: 1. While it may be confusing to the Python scriptor on Win64 that he has to check for win*32*, that is something that he will learn the first time. It is better than the alternative of the scriptor happily using "win64" and then that code not running on Win32 for no good reason. 2. The main question is: is Win64 so much more like Win32 than different from it that the common-case general Python programmer should not ever have to make the differentiation in his Python code. Or, at least, enough so that such differentiation by the Python scriptor is rare enough that some other provided mechanism is sufficient (even preferable). Currently the answer is yes. Hopefully MS will not change this answer.
This commit is contained in:
parent
230cae7474
commit
da5cc82d59
|
@ -234,7 +234,10 @@ typedef int pid_t;
|
|||
/* End of compilers - finish up */
|
||||
|
||||
#if defined(MS_WIN64)
|
||||
#define PLATFORM "win64"
|
||||
/* maintain "win32" sys.platform for backward compatibility of Python code,
|
||||
the Win64 API should be close enough to the Win32 API to make this
|
||||
preferable */
|
||||
#define PLATFORM "win32"
|
||||
#define SIZEOF_VOID_P 8
|
||||
#elif defined(MS_WIN32)
|
||||
#define PLATFORM "win32"
|
||||
|
|
Loading…
Reference in New Issue