If `zip` gets a `strict` keyword-only parameter, a slightly related
question is whether `map` should also receive one?

`map` can be used as zip + transform:

    map(func, x, y)
    (func(a, b) for a, b in zip(x, y))  # similar

Now if I'm using the first option and I want to enable the strict check,
I need to switch either to the second one or use `itertools.starmap`
with `zip`:

    it.starmap(func, zip(x, y, strict=True))
    (func(a, b) for a, b in zip(x, y, strict=True))

    map(func, x, y, strict=True)  # ?

Admittedly the word "strict" in the context of `map` would be rather
confusing.

On 01.05.20 20:10, Brandt Bucher wrote:
I have pushed a first draft of PEP 618:

https://www.python.org/dev/peps/pep-0618

Please let me know what you think – I'd love to hear any *new* feedback that 
hasn't yet been addressed in the PEP!

Brandt
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/ZBB5L2I45PNLTRW7CCV4FDJO5DB7M5UT/
Code of Conduct: http://python.org/psf/codeofconduct/
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/6FN6DJOJ4PIMWLSSP5XS5MCWB7T3C4WR/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to