On 14/01/21 6:17 am, Paul Sokolovsky wrote:
For
example, print() would be considered "pure", as its purpose is to
provide program output, not arbitrarily change program state

That definition of purity wouldn't really help with optimisations,
though, because optimising away a print() call would still cause
a visible change in the program's behaviour.

--
Greg
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/B6VDVU7UOB5QNILEJ44J7JOSVBF7WDBF/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to