@@ -3190,7 +3190,6 @@ class inexact(number[_NBit1]): # type: ignore
3190
3190
def __getnewargs__ (self : inexact [_64Bit ]) -> tuple [float , ...]: ...
3191
3191
3192
3192
_IntType = TypeVar ("_IntType" , bound = integer [Any ])
3193
- _FloatType = TypeVar ('_FloatType' , bound = floating [Any ])
3194
3193
3195
3194
class floating (inexact [_NBit1 ]):
3196
3195
def __init__ (self , value : _FloatValue = ..., / ) -> None : ...
@@ -3620,27 +3619,30 @@ class busdaycalendar:
3620
3619
@property
3621
3620
def holidays (self ) -> NDArray [datetime64 ]: ...
3622
3621
3623
- class finfo (Generic [_FloatType ]):
3624
- dtype : dtype [_FloatType ]
3625
- bits : int
3626
- eps : _FloatType
3627
- epsneg : _FloatType
3628
- iexp : int
3629
- machep : int
3630
- max : _FloatType
3631
- maxexp : int
3632
- min : _FloatType
3633
- minexp : int
3634
- negep : int
3635
- nexp : int
3636
- nmant : int
3637
- precision : int
3638
- resolution : _FloatType
3639
- smallest_subnormal : _FloatType
3640
- @property
3641
- def smallest_normal (self ) -> _FloatType : ...
3642
- @property
3643
- def tiny (self ) -> _FloatType : ...
3622
+
3623
+ _FloatType_co = TypeVar ('_FloatType_co' , bound = floating [Any ], covariant = True )
3624
+
3625
+ class finfo (Generic [_FloatType_co ]):
3626
+ dtype : Final [dtype [_FloatType_co ]]
3627
+ bits : Final [int ]
3628
+ eps : Final [_FloatType_co ]
3629
+ epsneg : Final [_FloatType_co ]
3630
+ iexp : Final [int ]
3631
+ machep : Final [int ]
3632
+ max : Final [_FloatType_co ]
3633
+ maxexp : Final [int ]
3634
+ min : Final [_FloatType_co ]
3635
+ minexp : Final [int ]
3636
+ negep : Final [int ]
3637
+ nexp : Final [int ]
3638
+ nmant : Final [int ]
3639
+ precision : Final [int ]
3640
+ resolution : Final [_FloatType_co ]
3641
+ smallest_subnormal : Final [_FloatType_co ]
3642
+ @property
3643
+ def smallest_normal (self ) -> _FloatType_co : ...
3644
+ @property
3645
+ def tiny (self ) -> _FloatType_co : ...
3644
3646
@overload
3645
3647
def __new__ (
3646
3648
cls , dtype : inexact [_NBit1 ] | _DTypeLike [inexact [_NBit1 ]]
@@ -3654,18 +3656,22 @@ class finfo(Generic[_FloatType]):
3654
3656
cls , dtype : str
3655
3657
) -> finfo [floating [Any ]]: ...
3656
3658
3657
- class iinfo (Generic [_IntType ]):
3658
- dtype : dtype [_IntType ]
3659
- kind : LiteralString
3660
- bits : int
3661
- key : LiteralString
3659
+ _IntType_co = TypeVar ("_IntType_co" , bound = integer [Any ], covariant = True )
3660
+
3661
+ class iinfo (Generic [_IntType_co ]):
3662
+ dtype : Final [dtype [_IntType_co ]]
3663
+ kind : Final [LiteralString ]
3664
+ bits : Final [int ]
3665
+ key : Final [LiteralString ]
3662
3666
@property
3663
3667
def min (self ) -> int : ...
3664
3668
@property
3665
3669
def max (self ) -> int : ...
3666
3670
3667
3671
@overload
3668
- def __new__ (cls , dtype : _IntType | _DTypeLike [_IntType ]) -> iinfo [_IntType ]: ...
3672
+ def __new__ (
3673
+ cls , dtype : _IntType_co | _DTypeLike [_IntType_co ]
3674
+ ) -> iinfo [_IntType_co ]: ...
3669
3675
@overload
3670
3676
def __new__ (cls , dtype : int | type [int ]) -> iinfo [int_ ]: ...
3671
3677
@overload
0 commit comments