On Wed, Oct 27, 2021 at 2:47 AM Eric V. Smith <e...@trueblade.com> wrote:
> Okay. I look forward to your thoughts. Omitting late-bound arguments or
> defaults would not be acceptable.

No, I agree. We have to still be able to introspect them.

At the moment, when you look at a function's defaults, they are all
values. With this change, some would be values and some would be
markers saying that code would be executed. The markers would
incorporate the source code for the expression in question (for human
readability), but I don't think they can include anything else; it
seems a bit costly to retain the AST, plus it's not going to be
dependable across versions anyway (the AST can change at any time).

ChrisA
_______________________________________________
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/UIJIDTTU5GMK24II3BYHHXVRJCEI2JZ5/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to