I can't say that I like the look of pseudo-assignment to question mark:
for ? in range(20):
...
but I could probably learn to live with it. But one of your
rationalisations:
> and makes it more obvious that
> the actual intent is for the value to be unused -- since it is entirely
> impossible to use it.
is actually an anti-feature, in my opinion.
I think that people might like the idea of not actually binding a value
in situations like this:
a, *?, b = expression
until you end up with something unexpected in a and b and need to debug
what it going on, either in a debugger or with print:
a, *?, b = expression
print(?) # wait this doesn't work
In my opinion, having a convention to treat certain variables as
"unused" is great (I'm partial to `__` myself, to avoid clobbering the
special variable `_` in the REPL). But having that be a pseudo-variable
which is *actually* unused and unuseable strikes me as being an
attractive nuisance.
--
Steve
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at
https://mail.python.org/archives/list/[email protected]/message/OPUUJWBCK37CQXOYIFYSUIXFQSWTTCCA/
Code of Conduct: http://python.org/psf/codeofconduct/