Commit 8332ebce authored by Stefan Behnel's avatar Stefan Behnel

disable optimised sequence unpacking for bytes/str - hard to get right for Py2/Py3

parent 18cf9d56
......@@ -432,9 +432,7 @@ def flatten_parallel_assignments(input, output):
# individual elements. This transformation is applied
# recursively, so that nested structures get matched as well.
rhs = input[-1]
if (not (rhs.is_sequence_constructor or
(rhs.is_string_literal and not (rhs.type.is_string or
rhs.type is Builtin.bytes_type)))
if (not (rhs.is_sequence_constructor or isinstance(rhs, ExprNodes.UnicodeNode))
or not sum([lhs.is_sequence_constructor for lhs in input[:-1]])):
output.append(input)
return
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment