From 7364af2d8cd72467bbb3bf135b29fae47105b232 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Sun, 2 Feb 2014 02:38:22 +0200 Subject: Factor out m_seq_get_fast_slice_indexes() fucntions as sequence helper. Takes slice object and sequence length and computes subsequence indexes for case of slice step=1. --- py/obj.h | 1 + 1 file changed, 1 insertion(+) (limited to 'py/obj.h') diff --git a/py/obj.h b/py/obj.h index 0680e6fb1..45430d4a1 100644 --- a/py/obj.h +++ b/py/obj.h @@ -395,3 +395,4 @@ typedef struct _mp_obj_classmethod_t { // sequence helpers void mp_seq_multiply(const void *items, uint item_sz, uint len, uint times, void *dest); +bool m_seq_get_fast_slice_indexes(machine_uint_t len, mp_obj_t slice, machine_uint_t *begin, machine_uint_t *end); -- cgit v1.2.3