21.11.17 10:54, Kirill Balunov пише:
Of course this version has drawbacks (the first that come to mind):
1. Will *b see change if rhs is some muttable sequence?
2. Will *b one way iterator or somethong like range?
But still it seems to me that the "iterator way" has more useful
applications.
Your implementation iterates seq multiple times. But iterable unpacking
syntax works with an arbitrary iterable, and iterates it only once.
Changing the result of iterable unpacking will break existing code that
depends on the result been a list.
And you already have mentioned a question about mutable sequence.
If these conditions and restrictions suit you, you can use your
good_star_exp() in your code or share it with others. But the semantic
of iterable unpacking can't be changed.
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/