Closed
Description
Bug report
The function object has a number of settable attributes. For the following, setting the value calls _PyFunction_SetVersion(op, 0)
:
__defaults__
__kwdefaults__
__code__
__annotations__
But for the following, there is no such call:
__dict__
__name__
__qualname__
__type_params__
I don't think any of these four should affect the interpreter loop, but neither should __annotations__
. Should these setters also set the version for consistency, or should __annotations__
not set it as changing the annotations shouldn't affect the runtime?
cc @markshannon who added this in #27078.