summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Horel <guillaume.horel@gmail.com>2023-11-30 14:38:35 -0500
committerGuillaume Horel <guillaume.horel@gmail.com>2023-11-30 14:38:35 -0500
commit6917704a1a1a0f8474c069c1492934b8546615ce (patch)
treec8f815a7a42d0b12003fc25001628954e43f82a0
parentfca0caa31743af344ff53a1f7b7a5a7e2bc89c18 (diff)
downloadpyisda-6917704a1a1a0f8474c069c1492934b8546615ce.tar.gz
add needed cast
-rw-r--r--pyisda/curve.pyx2
1 files changed, 1 insertions, 1 deletions
diff --git a/pyisda/curve.pyx b/pyisda/curve.pyx
index 1eadc2e..de0d0e6 100644
--- a/pyisda/curve.pyx
+++ b/pyisda/curve.pyx
@@ -553,7 +553,7 @@ cdef class YieldCurve(Curve):
r[i] = JpmcdsZeroPrice(curve, pydate_to_TDate(np_datetimes[i]))
elif isinstance(d2, pd.Series):
np_dates = d2.values.view("int")
- r = np.PyArray_EMPTY(1, &np_dates.shape[0], np.NPY_DOUBLE, 0)
+ r = np.PyArray_EMPTY(1, <np.npy_intp*>&np_dates.shape[0], np.NPY_DOUBLE, 0)
for i in range(r.shape[0]):
date_c = np_dates[i] / scale + 134774
r[i] = JpmcdsZeroPrice(curve, date_c)