Skip to content

Commit

Permalink
TYP: add correct type hint for maybe_downcast_to_dtype
Browse files Browse the repository at this point in the history
  • Loading branch information
arw2019 committed Oct 15, 2020
1 parent 1724acb commit 1c9bfe8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pandas/core/dtypes/cast.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def is_nested_object(obj) -> bool:
return False


def maybe_downcast_to_dtype(result, dtype: Dtype):
def maybe_downcast_to_dtype(result, dtype: Union[str, np.dtype]):
"""
try to cast to the specified dtype (e.g. convert back to bool/int
or could be an astype of float64->float32
Expand Down

0 comments on commit 1c9bfe8

Please sign in to comment.