Skip to content

CLN: remove unnecessary CategoricalIndex._convert_arr_indexer #36705

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 7 commits into from
Sep 30, 2020
10 changes: 0 additions & 10 deletions pandas/core/indexes/category.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@

from pandas.core import accessor
from pandas.core.arrays.categorical import Categorical, contains
import pandas.core.common as com
from pandas.core.construction import extract_array
import pandas.core.indexes.base as ibase
from pandas.core.indexes.base import Index, _index_shared_docs, maybe_extract_name
Expand Down Expand Up @@ -574,15 +573,6 @@ def _convert_list_indexer(self, keyarr):

return self.get_indexer(keyarr)

@doc(Index._convert_arr_indexer)
def _convert_arr_indexer(self, keyarr):
keyarr = com.asarray_tuplesafe(keyarr)

if self.categories._defer_to_indexing:
return keyarr

return self._shallow_copy(keyarr)

@doc(Index._maybe_cast_slice_bound)
def _maybe_cast_slice_bound(self, label, side, kind):
if kind == "loc":
Expand Down