Skip to content

Commit 09c1381

Browse files
committed
COMPAT: 32-bit indexing compat
xref pandas-dev#20939
1 parent 2299693 commit 09c1381

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/core/indexing.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1318,7 +1318,7 @@ def _convert_to_indexer(self, obj, axis=None, is_setter=False):
13181318
(indexer,
13191319
missing) = labels.get_indexer_non_unique(objarr)
13201320
# 'indexer' has dupes, create 'check' using 'missing'
1321-
check = np.zeros(len(objarr))
1321+
check = np.zeros(len(objarr), dtype=np.intp)
13221322
check[missing] = -1
13231323

13241324
mask = check == -1
@@ -2469,7 +2469,7 @@ def maybe_convert_indices(indices, n):
24692469
if len(indices) == 0:
24702470
# If list is empty, np.array will return float and cause indexing
24712471
# errors.
2472-
return np.empty(0, dtype=np.int_)
2472+
return np.empty(0, dtype=np.intp)
24732473

24742474
mask = indices < 0
24752475
if mask.any():

0 commit comments

Comments
 (0)