diff options
| author | stijn | 2019-07-02 10:28:44 +0200 |
|---|---|---|
| committer | Damien George | 2019-08-17 23:23:17 +1000 |
| commit | af5c998f37ddc62abfd36e0b8be511c392fc25d8 (patch) | |
| tree | 3cdabcc1b382ee0f1ce87a5ad1cabd8c96b2fa8b /ports/unix/mpconfigport.h | |
| parent | 3eff81288cb494c7d1a9fcf0a82d4e21bbd92dd8 (diff) | |
py/modmath: Implement math.isclose() for non-complex numbers.
As per PEP 485, this function appeared in for Python 3.5. Configured via
MICROPY_PY_MATH_ISCLOSE which is disabled by default, but enabled for the
ports which already have MICROPY_PY_MATH_SPECIAL_FUNCTIONS enabled.
Diffstat (limited to 'ports/unix/mpconfigport.h')
| -rw-r--r-- | ports/unix/mpconfigport.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/ports/unix/mpconfigport.h b/ports/unix/mpconfigport.h index 123cad2bc..23c562e5a 100644 --- a/ports/unix/mpconfigport.h +++ b/ports/unix/mpconfigport.h @@ -104,6 +104,7 @@ #ifndef MICROPY_PY_MATH_SPECIAL_FUNCTIONS #define MICROPY_PY_MATH_SPECIAL_FUNCTIONS (1) #endif +#define MICROPY_PY_MATH_ISCLOSE (MICROPY_PY_MATH_SPECIAL_FUNCTIONS) #define MICROPY_PY_CMATH (1) #define MICROPY_PY_IO_IOBASE (1) #define MICROPY_PY_IO_FILEIO (1) |
