Cleanup: pass sizeof array element to PyC_AsArray
Replace the is_double argument which was only used for single/double precision floats. This allows supporting different sized int types more easily.
This commit is contained in:
@@ -1836,7 +1836,7 @@ static int BPy_IDArray_ass_slice(BPy_IDArray *self, int begin, int end, PyObject
|
||||
/* NOTE: we count on int/float being the same size here */
|
||||
vec = MEM_mallocN(alloc_len, "array assignment");
|
||||
|
||||
if (PyC_AsArray(vec, seq, size, py_type, is_double, "slice assignment: ") == -1) {
|
||||
if (PyC_AsArray(vec, elem_size, seq, size, py_type, "slice assignment: ") == -1) {
|
||||
MEM_freeN(vec);
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user