py/modsys: Add optional sys.tracebacklimit attribute.

With behaviour as per CPython.

Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
Damien George
2021-07-27 00:41:27 +10:00
parent bc181550a4
commit cac939ddc3
10 changed files with 117 additions and 3 deletions

View File

@@ -34,6 +34,7 @@
#define MICROPY_REPL_EMACS_WORDS_MOVE (1)
#define MICROPY_REPL_EMACS_EXTRA_WORDS_MOVE (1)
#define MICROPY_WARNINGS_CATEGORY (1)
#define MICROPY_MODULE_ATTR_DELEGATION (1)
#define MICROPY_MODULE_GETATTR (1)
#define MICROPY_PY_DELATTR_SETATTR (1)
#define MICROPY_PY_ALL_INPLACE_SPECIAL_METHODS (1)
@@ -44,6 +45,7 @@
#define MICROPY_PY_BUILTINS_HELP (1)
#define MICROPY_PY_BUILTINS_HELP_MODULES (1)
#define MICROPY_PY_SYS_GETSIZEOF (1)
#define MICROPY_PY_SYS_TRACEBACKLIMIT (1)
#define MICROPY_PY_MATH_CONSTANTS (1)
#define MICROPY_PY_MATH_FACTORIAL (1)
#define MICROPY_PY_URANDOM_EXTRA_FUNCS (1)