summaryrefslogtreecommitdiff
path: root/py/objtuple.c
diff options
context:
space:
mode:
authorScott Shawcroft <scott@tannewt.org>2019-12-13 14:52:04 -0800
committerScott Shawcroft <scott@tannewt.org>2019-12-13 14:52:04 -0800
commit7f7105d36d5775e6b7842a24f06604a229b2aae3 (patch)
tree1967c95d5ae38d636c39483f6e714c4fabed77ca /py/objtuple.c
parentdc8dd6df20f4904917169f4ec1172c8f3827e822 (diff)
Fix tuple test
Diffstat (limited to 'py/objtuple.c')
-rw-r--r--py/objtuple.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/py/objtuple.c b/py/objtuple.c
index 7a4c09ab7..cc69f5469 100644
--- a/py/objtuple.c
+++ b/py/objtuple.c
@@ -181,7 +181,7 @@ mp_obj_t mp_obj_tuple_binary_op(mp_binary_op_t op, mp_obj_t lhs, mp_obj_t rhs) {
mp_obj_t mp_obj_tuple_subscr(mp_obj_t self_in, mp_obj_t index, mp_obj_t value) {
if (value == MP_OBJ_SENTINEL) {
// load
- mp_obj_tuple_t *self = MP_OBJ_TO_PTR(self_in);
+ mp_obj_tuple_t *self = mp_instance_cast_to_native_base(self_in, MP_OBJ_FROM_PTR(&mp_type_tuple));
#if MICROPY_PY_BUILTINS_SLICE
if (MP_OBJ_IS_TYPE(index, &mp_type_slice)) {
mp_bound_slice_t slice;