summaryrefslogtreecommitdiffstatshomepage
path: root/py/mpconfig.h
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-05-22 00:13:44 +0300
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2016-05-22 00:13:44 +0300
commit1b5abfcaae0188233415b37dcc0a3df1c7ee0656 (patch)
tree3b04d97917e3323ad0c8b66d4f12eef346dd88df /py/mpconfig.h
parent2c573f00b8ce1ef67e8e754b5231e061fbd5b064 (diff)
downloadmicropython-1b5abfcaae0188233415b37dcc0a3df1c7ee0656.tar.gz
micropython-1b5abfcaae0188233415b37dcc0a3df1c7ee0656.zip
py/objstr: Implement str.center().
Disabled by default, enabled in unix port. Need for this method easily pops up when working with text UI/reporting, and coding workalike manually again and again counter-productive.
Diffstat (limited to 'py/mpconfig.h')
-rw-r--r--py/mpconfig.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h
index a6b4a4ab0d..92f17724f4 100644
--- a/py/mpconfig.h
+++ b/py/mpconfig.h
@@ -589,6 +589,11 @@ typedef double mp_float_t;
#define MICROPY_PY_BUILTINS_STR_UNICODE (0)
#endif
+// Whether str.center() method provided
+#ifndef MICROPY_PY_BUILTINS_STR_CENTER
+#define MICROPY_PY_BUILTINS_STR_CENTER (0)
+#endif
+
// Whether str.splitlines() method provided
#ifndef MICROPY_PY_BUILTINS_STR_SPLITLINES
#define MICROPY_PY_BUILTINS_STR_SPLITLINES (0)