How about using the typing return arrow -> to indicate the return of the preceding goes as a first parameter in the function: 1 -> add(2) I don’t like the fact this is used only as a first parameter. What if you want the preceding output to go as a second parameter? Abdulla
Sent from my iPhone > On 29 Nov 2021, at 9:55 PM, Chris Angelico <ros...@gmail.com> wrote: > > 1 |> add(2) > > is exactly equivalent to this: > > add(1, 2) > > then neither the iterator nor the consumer needs to be aware of the > new protocol. > > I don't like that syntax though, and this will live or die on a good syntax. _______________________________________________ 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/P4R4NSNVWGLADQCA3HDVAR26LQP2WJ6D/ Code of Conduct: http://python.org/psf/codeofconduct/