Skip to content

Commit eed6176

Browse files
committed
use np.issubdtype instead of is_string_dtype
1 parent b70c6ab commit eed6176

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/core/dtypes/cast.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1851,7 +1851,7 @@ def maybe_cast_to_integer_array(
18511851
# doesn't handle `uint64` correctly.
18521852
arr = np.asarray(arr)
18531853

1854-
if is_string_dtype(arr):
1854+
if np.issubdtype(arr.dtype, str):
18551855
return casted
18561856

18571857
if is_unsigned_integer_dtype(dtype) and (arr < 0).any():

0 commit comments

Comments
 (0)