Describe the issue:
Originally reported in finch-tensor/finch-tensor#248 (comment)
Possibly ctypes conversions of numpy scalars all share the same buffer.
Reproduce the code example:
import numpy as np
import numpy.ctypeslib as ctl
a = np.int64(2)
b = np.int64(1)
s1 = ctl.as_ctypes(a)
s2 = ctl.as_ctypes(b)
print(s1.value, s2.value)
# this prints 1 1
Python and NumPy Versions:
2.3.3
3.12.11 | packaged by conda-forge | (main, Jun 4 2025, 14:38:53) [Clang 18.1.8 ]
Describe the issue:
Originally reported in finch-tensor/finch-tensor#248 (comment)
Possibly ctypes conversions of numpy scalars all share the same buffer.
Reproduce the code example:
Python and NumPy Versions:
2.3.3
3.12.11 | packaged by conda-forge | (main, Jun 4 2025, 14:38:53) [Clang 18.1.8 ]