summaryrefslogtreecommitdiff
path: root/py/mpconfig.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2017-01-21 23:17:51 +1100
committerDamien George <damien.p.george@gmail.com>2017-01-22 11:56:16 +1100
commit9f04dfb568b8af339ec34ea1a94fb2eb8890bf8c (patch)
tree125d6d250a4fee0f96db44c6a52e8b0027c65ece /py/mpconfig.h
parentbd3dd9296b256d91e6021e481b7f4f5c6ae35a92 (diff)
py: Add builtin help function to core, with default help msg.
This builtin is configured using MICROPY_PY_BUILTINS_HELP, and is disabled by default.
Diffstat (limited to 'py/mpconfig.h')
-rw-r--r--py/mpconfig.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h
index 6d1893717..70ad98daa 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -759,6 +759,17 @@ typedef double mp_float_t;
#define MICROPY_PY_BUILTINS_MIN_MAX (1)
#endif
+// Whether to provide the help function
+#ifndef MICROPY_PY_BUILTINS_HELP
+#define MICROPY_PY_BUILTINS_HELP (0)
+#endif
+
+// Use this to configure the help text shown for help(). It should be a
+// variable with the type "const char*". A sensible default is provided.
+#ifndef MICROPY_PY_BUILTINS_HELP_TEXT
+#define MICROPY_PY_BUILTINS_HELP_TEXT mp_help_default_text
+#endif
+
// Whether to set __file__ for imported modules
#ifndef MICROPY_PY___FILE__
#define MICROPY_PY___FILE__ (1)