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
881d9af0
Commit
881d9af0
authored
Apr 10, 2014
by
Paul Sokolovsky
Browse files
objstr: Add TODO-optimize for using .join with arbitrary iterable.
parent
87bb093e
Changes
1
Hide whitespace changes
Inline
Side-by-side
py/objstr.c
View file @
881d9af0
...
...
@@ -330,6 +330,7 @@ STATIC mp_obj_t str_join(mp_obj_t self_in, mp_obj_t arg) {
}
else
{
if
(
!
MP_OBJ_IS_TYPE
(
arg
,
&
mp_type_list
))
{
// arg is not a list, try to convert it to one
// TODO: Try to optimize?
arg
=
mp_type_list
.
make_new
((
mp_obj_t
)
&
mp_type_list
,
1
,
0
,
&
arg
);
}
mp_obj_list_get
(
arg
,
&
seq_len
,
&
seq_items
);
...
...
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