make computed var generic over mapping (#4762)

This commit is contained in:
Khaleel Al-Adhami 2025-02-05 16:16:30 -08:00 committed by Masen Furer
parent ead2796c34
commit 080d0c0908
No known key found for this signature in database
GPG Key ID: B0008AD22B3B3A95

View File

@ -2219,10 +2219,10 @@ class ComputedVar(Var[RETURN_TYPE]):
@overload
def __get__(
self: ComputedVar[Mapping[DICT_KEY, DICT_VAL]],
self: ComputedVar[MAPPING_TYPE],
instance: None,
owner: Type,
) -> ObjectVar[Mapping[DICT_KEY, DICT_VAL]]: ...
) -> ObjectVar[MAPPING_TYPE]: ...
@overload
def __get__(
@ -2465,10 +2465,10 @@ class AsyncComputedVar(ComputedVar[RETURN_TYPE]):
@overload
def __get__(
self: AsyncComputedVar[Mapping[DICT_KEY, DICT_VAL]],
self: AsyncComputedVar[MAPPING_TYPE],
instance: None,
owner: Type,
) -> ObjectVar[Mapping[DICT_KEY, DICT_VAL]]: ...
) -> ObjectVar[MAPPING_TYPE]: ...
@overload
def __get__(