Commit eef0e829 authored by Matti Picus's avatar Matti Picus
Browse files

use strigified _MSC_VER for the compiler version, like CPython

parent 08b530929d7b
...@@ -19,7 +19,7 @@ def get_compiler_info(): ...@@ -19,7 +19,7 @@ def get_compiler_info():
if platform.name == 'msvc': if platform.name == 'msvc':
# XXX hard-code the MSC version, I don't feel like computing it dynamically # XXX hard-code the MSC version, I don't feel like computing it dynamically
_C_COMPILER_INFO = '"MSC v.%d 32 bit"' % (platform.version * 10 + 600) _C_COMPILER_INFO = '"MSC v." Py_STR(_MSC_VER)'
else: else:
_C_COMPILER_INFO = '("GCC " __VERSION__)' _C_COMPILER_INFO = '("GCC " __VERSION__)'
......
...@@ -123,3 +123,7 @@ ...@@ -123,3 +123,7 @@
# define MS_WINDOWS /* a synonym */ # define MS_WINDOWS /* a synonym */
#endif #endif
#endif #endif
/* stringify a constant */
#define Py_XSTR(x) #x
#define Py_STR(x) Py_XSTR(x)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment