mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 13:34:58 +08:00
Make Reversible covariant. Fixes #19. (Though it does not seem to be *necessary*.)
This commit is contained in:
@@ -60,7 +60,7 @@ class SupportsRound(Generic[_T]):
|
||||
@abstractmethod
|
||||
def __round__(self, ndigits: int = ...) -> _T: ...
|
||||
|
||||
class Reversible(Generic[_T]):
|
||||
class Reversible(Generic[_T_co]):
|
||||
@abstractmethod
|
||||
def __reversed__(self) -> Iterator[_T]: ...
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@ class SupportsRound(Generic[_T]):
|
||||
@abstractmethod
|
||||
def __round__(self, ndigits: int = ...) -> _T: ...
|
||||
|
||||
class Reversible(Generic[_T]):
|
||||
class Reversible(Generic[_T_co]):
|
||||
@abstractmethod
|
||||
def __reversed__(self) -> Iterator[_T]: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user