summaryrefslogtreecommitdiffstatshomepage
path: root/tests/basics/builtin_override.py
Commit message (Collapse)AuthorAge
* tests: Add tests for overriding builtins.__import__.Damien George2019-07-31
|
* tests/basics: Convert "sys.exit()" to "raise SystemExit".Paul Sokolovsky2017-06-10
|
* tests/basic/[a-f]*: Make skippable.Paul Sokolovsky2017-02-15
| | | | For small ports which don't have all features enabled.
* py: Allow builtins to be overridden.Damien George2014-12-09
This patch adds a configuration option (MICROPY_CAN_OVERRIDE_BUILTINS) which, when enabled, allows to override all names within the builtins module. A builtins override dict is created the first time the user assigns to a name in the builtins model, and then that dict is searched first on subsequent lookups. Note that this implementation doesn't allow deleting of names. This patch also does some refactoring of builtins code, creating the modbuiltins.c file. Addresses issue #959.