On 5/13/21 10:46 AM, Eric V. Smith wrote:
>>> MISSING
<class '__main__.MISSING'>

I think a repr of just "MISSING", or maybe "dataclasses.MISSING" would be better.


I literally just went down this road--for a while there was a special sentinel value for the eval_str parameter to inspect.get_annotations().  The repr I went with was "<id>", e.g "<MISSING>".  It depends on how seriously you take the idea that eval(repr(x)) == x.  Certainly most objects don't actually support that, e.g., uh, object(), a type which I understand is available in most Python implementations.


Cheers,


//arry/

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

Reply via email to