Skip to content

COMPAT: 32-bit indexing compat #20989

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 10, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions pandas/_libs/index.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ from cpython.slice cimport PySlice_Check

import numpy as np
cimport numpy as cnp
from numpy cimport ndarray, float64_t, int32_t, int64_t, uint8_t, uint64_t
from numpy cimport (ndarray, float64_t, int32_t,
int64_t, uint8_t, uint64_t, intp_t)
cnp.import_array()

cdef extern from "numpy/arrayobject.h":
Expand Down Expand Up @@ -183,8 +184,8 @@ cdef class IndexEngine:

cdef _maybe_get_bool_indexer(self, object val):
cdef:
ndarray[cnp.uint8_t, ndim=1, cast=True] indexer
ndarray[int64_t, ndim=1] found
ndarray[uint8_t, ndim=1, cast=True] indexer
ndarray[intp_t, ndim=1] found
int count

indexer = self._get_index_values() == val
Expand Down
4 changes: 2 additions & 2 deletions pandas/_libs/index_class_helper.pxi.in
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ cdef class {{name}}Engine(IndexEngine):

cdef _maybe_get_bool_indexer(self, object val):
cdef:
ndarray[cnp.uint8_t, ndim=1, cast=True] indexer
ndarray[int64_t, ndim=1] found
ndarray[uint8_t, ndim=1, cast=True] indexer
ndarray[intp_t, ndim=1] found
ndarray[{{ctype}}] values
int count = 0

Expand Down