summaryrefslogtreecommitdiff
path: root/py/mpconfig.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2015-02-22 14:48:18 +0000
committerDamien George <damien.p.george@gmail.com>2015-02-22 14:48:18 +0000
commit5cbeacebdb8407425e692205f7333452e8a57784 (patch)
tree7862a270c4b0a78379994b7610b0856cb1826f7c /py/mpconfig.h
parent9ab94c468cb0d2a22eadbce2f493e016c462109e (diff)
py: Make math special functions configurable and disabled by default.
The implementation of these functions is very large (order 4k) and they are rarely used, so we don't enable them by default. They are however enabled in stmhal and unix, since we have the room.
Diffstat (limited to 'py/mpconfig.h')
-rw-r--r--py/mpconfig.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h
index b235d6fe6..bde8dfb9e 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -419,6 +419,11 @@ typedef double mp_float_t;
#define MICROPY_PY_MATH (1)
#endif
+// Whether to provide special math functions: math.{erf,erfc,gamma,lgamma}
+#ifndef MICROPY_PY_MATH_SPECIAL_FUNCTIONS
+#define MICROPY_PY_MATH_SPECIAL_FUNCTIONS (0)
+#endif
+
// Whether to provide "cmath" module
#ifndef MICROPY_PY_CMATH
#define MICROPY_PY_CMATH (0)