summaryrefslogtreecommitdiff
path: root/docs/examples/tutorial/external/py_version_hex.py
diff options
context:
space:
mode:
Diffstat (limited to 'docs/examples/tutorial/external/py_version_hex.py')
-rw-r--r--docs/examples/tutorial/external/py_version_hex.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/docs/examples/tutorial/external/py_version_hex.py b/docs/examples/tutorial/external/py_version_hex.py
new file mode 100644
index 000000000..3b19d0d02
--- /dev/null
+++ b/docs/examples/tutorial/external/py_version_hex.py
@@ -0,0 +1,4 @@
+from cython.cimports.cpython.version import PY_VERSION_HEX
+
+# Python version >= 3.2 final ?
+print(PY_VERSION_HEX >= 0x030200F0)