On Sat, Oct 23, 2021 at 7:00 PM Steven D'Aprano <st...@pearwood.info> wrote:
> I challenge that assertion. I've never knowingly seen a function where > the late binding is "buried deeper in the function", certainly not deep > enough that it is not obvious. It is a very strong convention that such > late binding operations occur early in the function body. > > You know, before you use the parameter, not afterwards *wink* > I've seen this and recently. The case is where the evaluation of the default expression might be expensive, and is only used depending on the value of other arguments. --- Bruce
_______________________________________________ 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/YMNQPJTVFUBHR3WALI2TRC2UPKHREYJ5/ Code of Conduct: http://python.org/psf/codeofconduct/