summaryrefslogtreecommitdiffstats
path: root/Include/pymath.h
diff options
context:
space:
mode:
authorGuido van Rossum <guido@dropbox.com>2016-08-15 16:12:52 (GMT)
committerGuido van Rossum <guido@dropbox.com>2016-08-15 16:12:52 (GMT)
commit0a891d70ded5fa8b1e6491529a3b531f521b5ae1 (patch)
treee26a1c826888bbd3c40b7775406062ab1b32cca5 /Include/pymath.h
parent6349612a8e5d5fcb3405e59242b6a2df3127585a (diff)
downloadcpython-0a891d70ded5fa8b1e6491529a3b531f521b5ae1.zip
cpython-0a891d70ded5fa8b1e6491529a3b531f521b5ae1.tar.gz
cpython-0a891d70ded5fa8b1e6491529a3b531f521b5ae1.tar.bz2
Issue #12345: Add mathemathcal constant tau to math and cmath.
Patch by Lisa Roach. See also PEP 628.
Diffstat (limited to 'Include/pymath.h')
-rw-r--r--Include/pymath.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/Include/pymath.h b/Include/pymath.h
index ed76053..894362e 100644
--- a/Include/pymath.h
+++ b/Include/pymath.h
@@ -55,6 +55,12 @@ extern double pow(double, double);
#define Py_MATH_E 2.7182818284590452354
#endif
+/* Tau (2pi) to 40 digits, taken from tauday.com/tau-digits. */
+#ifndef Py_MATH_TAU
+#define Py_MATH_TAU 6.2831853071795864769252867665590057683943L
+#endif
+
+
/* On x86, Py_FORCE_DOUBLE forces a floating-point number out of an x87 FPU
register and into a 64-bit memory location, rounding from extended
precision to double precision in the process. On other platforms it does