Skip to content

Commit a3fcca4

Browse files
authored
replace self param with more appropriate cls in classmethods (GH-31402)
1 parent 1f9d4c9 commit a3fcca4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Lib/_collections_abc.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -871,7 +871,7 @@ class KeysView(MappingView, Set):
871871
__slots__ = ()
872872

873873
@classmethod
874-
def _from_iterable(self, it):
874+
def _from_iterable(cls, it):
875875
return set(it)
876876

877877
def __contains__(self, key):
@@ -889,7 +889,7 @@ class ItemsView(MappingView, Set):
889889
__slots__ = ()
890890

891891
@classmethod
892-
def _from_iterable(self, it):
892+
def _from_iterable(cls, it):
893893
return set(it)
894894

895895
def __contains__(self, item):

0 commit comments

Comments
 (0)