mirror of
https://github.com/ROCm/jax.git
synced 2025-04-16 03:46:06 +00:00
Fix Windows build failure.
ssize_t isn't defined by MSVC. However itemsize() will always be small, so it's safe to use `int` here.
This commit is contained in:
parent
daa8ec2c4b
commit
e8e1c18041
@ -31,7 +31,7 @@ class dtype : public nanobind::object {
|
||||
public:
|
||||
NB_OBJECT_DEFAULT(dtype, object, "dtype", PyArray_DescrCheck); // NOLINT
|
||||
|
||||
ssize_t itemsize() const { return nanobind::cast<ssize_t>(attr("itemsize")); }
|
||||
int itemsize() const { return nanobind::cast<int>(attr("itemsize")); }
|
||||
|
||||
/// Single-character code for dtype's kind.
|
||||
/// For example, floating point types are 'f' and integral types are 'i'.
|
||||
|
Loading…
x
Reference in New Issue
Block a user