Open fc-asad opened 7 months ago
I have seen code where a copy/deepcopy of an immutable data is made. As far as I understand, it is a useless operation.
Pylint should detect when copy/deepcopy of an immutable object is made and generate an error.
No response
+1, but inferring if something is immutable is hard, so the check would be limited to known immutable type or the false positives would make this check unusable.
Current problem
I have seen code where a copy/deepcopy of an immutable data is made. As far as I understand, it is a useless operation.
Desired solution
Pylint should detect when copy/deepcopy of an immutable object is made and generate an error.
Additional context
No response