Skip to content

Commit 918892b

Browse files
authored
Make dtype::num() return type consistent with other functions (#3995)
1 parent c5fa343 commit 918892b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/pybind11/numpy.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,7 +604,7 @@ class dtype : public object {
604604
}
605605

606606
/// type number of dtype.
607-
ssize_t num() const {
607+
int num() const {
608608
// Note: The signature, `dtype::num` follows the naming of NumPy's public
609609
// Python API (i.e., ``dtype.num``), rather than its internal
610610
// C API (``PyArray_Descr::type_num``).

0 commit comments

Comments
 (0)