Skip to content

Commit e459658

Browse files
jbrockmendeljreback
authored andcommitted
Make khash its own extension (pandas-dev#18472)
1 parent d3c3c2b commit e459658

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

pandas/_libs/src/khash.pxd renamed to pandas/_libs/khash.pxd

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# -*- coding: utf-8 -*-
2+
# cython: profile=False
13
from cpython cimport PyObject
24
from numpy cimport int64_t, uint64_t, int32_t, uint32_t, float64_t
35

pandas/_libs/tslibs/resolution.pyx

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ np.import_array()
1010

1111
from util cimport is_string_object, get_nat
1212

13-
from khash cimport (
13+
from pandas._libs.khash cimport (
1414
khiter_t,
1515
kh_destroy_int64, kh_put_int64,
1616
kh_init_int64, kh_int64_t,

setup.py

+3-5
Original file line numberDiff line numberDiff line change
@@ -497,7 +497,7 @@ def pxd(name):
497497
'pyxfile': '_libs/hashing'},
498498
'_libs.hashtable': {
499499
'pyxfile': '_libs/hashtable',
500-
'pxdfiles': ['_libs/hashtable', '_libs/missing'],
500+
'pxdfiles': ['_libs/hashtable', '_libs/missing', '_libs/khash'],
501501
'depends': (['pandas/_libs/src/klib/khash_python.h'] +
502502
_pxi_dep['hashtable'])},
503503
'_libs.index': {
@@ -554,7 +554,6 @@ def pxd(name):
554554
'_libs.tslib': {
555555
'pyxfile': '_libs/tslib',
556556
'pxdfiles': ['_libs/src/util',
557-
'_libs/src/khash',
558557
'_libs/tslibs/conversion',
559558
'_libs/tslibs/timedeltas',
560559
'_libs/tslibs/timestamps',
@@ -595,12 +594,11 @@ def pxd(name):
595594
'sources': np_datetime_sources},
596595
'_libs.tslibs.parsing': {
597596
'pyxfile': '_libs/tslibs/parsing',
598-
'pxdfiles': ['_libs/src/util',
599-
'_libs/src/khash']},
597+
'pxdfiles': ['_libs/src/util']},
600598
'_libs.tslibs.resolution': {
601599
'pyxfile': '_libs/tslibs/resolution',
602600
'pxdfiles': ['_libs/src/util',
603-
'_libs/src/khash',
601+
'_libs/khash',
604602
'_libs/tslibs/frequencies',
605603
'_libs/tslibs/timezones'],
606604
'depends': tseries_depends,

0 commit comments

Comments
 (0)