py/mpconfig: Enable 2-argument built-in next() at basic feature level.
This is a pretty fundamental built-in and having CPython-compatible behaviour is beneficial. The code size increase is not much, and ports/boards can still disable it if needed to save space. Addresses issue #5384. Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
@@ -1215,7 +1215,7 @@ typedef double mp_float_t;
|
||||
|
||||
// Support for calling next() with second argument
|
||||
#ifndef MICROPY_PY_BUILTINS_NEXT2
|
||||
#define MICROPY_PY_BUILTINS_NEXT2 (MICROPY_CONFIG_ROM_LEVEL_AT_LEAST_EVERYTHING)
|
||||
#define MICROPY_PY_BUILTINS_NEXT2 (MICROPY_CONFIG_ROM_LEVEL_AT_LEAST_BASIC_FEATURES)
|
||||
#endif
|
||||
|
||||
// Whether to support rounding of integers (incl bignum); eg round(123,-1)=120
|
||||
|
||||
Reference in New Issue
Block a user