[issue46404] RFE: @dataclasses.dataclass(slots=True) doesn't support methods using closures

2022-03-28 Thread STINNER Victor
STINNER Victor added the comment: See also bpo-45520: "Frozen dataclass deep copy doesn't work with __slots__" which is related but a different issue. -- ___ Python tracker

[issue46404] RFE: @dataclasses.dataclass(slots=True) doesn't support methods using closures

2022-03-28 Thread STINNER Victor
STINNER Victor added the comment: I changed the issue title to focus this issue on enhance dataclasses to support @dataclasses.dataclass(slots=True) on methods using closures: it would be a new Python 3.11 feature. I created https://bugs.python.org/issue47143 "Add functools.copy_class()