On 6/08/20 1:35 am, Marco Sulla wrote:
I suppose that what Greg Ewing suggests is a way to define a sort of
custom simple statement.
you could write
@print
"Hello"
My suggestion was only for decorating assignments to a bare name,
so that wouldn't have been legal.
But that was long before __set_name__ existed. It wouldn't be
necessary now for the use case I had in mind, and I can't think
of any other reason to want it.
--
Greg
_______________________________________________
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/KXIJYONZKRRKZUA2FLR2LBSQSDXHU3DC/
Code of Conduct: http://python.org/psf/codeofconduct/