summaryrefslogtreecommitdiff
path: root/py/obj.h
diff options
context:
space:
mode:
authorDan Halbert <halbert@adafruit.com>2019-05-15 18:40:32 -0400
committerGitHub <noreply@github.com>2019-05-15 18:40:32 -0400
commita888fe4c8e12144141b9c0730d3d25ebea33cbc7 (patch)
tree65e92ed5411bd0eb8808b50ef19eec923bc06cda /py/obj.h
parentbd69212a194849fd2d8d025ceaa4ecc0117753cc (diff)
parent00c39805f19abc6af565c1e3faee10c196d5f666 (diff)
Merge pull request #1888 from tannewt/iterable_group4.1.0-alpha.0
Improvements to Group
Diffstat (limited to 'py/obj.h')
-rw-r--r--py/obj.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/py/obj.h b/py/obj.h
index ae2bff190..773043b59 100644
--- a/py/obj.h
+++ b/py/obj.h
@@ -819,6 +819,10 @@ mp_obj_t mp_identity(mp_obj_t self);
MP_DECLARE_CONST_FUN_OBJ_1(mp_identity_obj);
mp_obj_t mp_identity_getiter(mp_obj_t self, mp_obj_iter_buf_t *iter_buf);
+// Generic iterator that uses unary op and subscr to iterate over a native type. It will be slower
+// than a custom iterator but applies broadly.
+mp_obj_t mp_obj_new_generic_iterator(mp_obj_t self, mp_obj_iter_buf_t *iter_buf);
+
// module
typedef struct _mp_obj_module_t {
mp_obj_base_t base;