Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
f1a99233
Commit
f1a99233
authored
Sep 27, 2015
by
Tom Soulanille
Committed by
Damien George
Sep 28, 2015
Browse files
py/objrange: Bugfix for range_subscr() when index is a slice object.
parent
2a8a564f
Changes
1
Hide whitespace changes
Inline
Side-by-side
py/objrange.c
View file @
f1a99233
...
...
@@ -148,9 +148,9 @@ STATIC mp_obj_t range_subscr(mp_obj_t self_in, mp_obj_t index, mp_obj_t value) {
mp_seq_get_fast_slice_indexes
(
len
,
index
,
&
slice
);
mp_obj_range_t
*
o
=
m_new_obj
(
mp_obj_range_t
);
o
->
base
.
type
=
&
mp_type_range
;
o
->
start
=
s
lice
.
start
;
o
->
stop
=
s
lice
.
sto
p
;
o
->
step
=
slice
.
step
;
o
->
start
=
s
elf
->
start
+
slice
.
start
*
self
->
step
;
o
->
stop
=
s
elf
->
start
+
slice
.
stop
*
self
->
ste
p
;
o
->
step
=
slice
.
step
*
self
->
step
;
return
o
;
}
#endif
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment