Test conversion of array of structs
Added test struct-values.translation.mem-aref.1 that creates an array of two struct-pairs, sets their values, then retrieves both pairs. This test fails: the returned first pair is actually the second, and the returned second pair is garbage. Repeating the same test gives different garbage. (with-foreign-object (p '(:struct struct-pair) 2) (setf (mem-aref p '(:struct struct-pair) 0) '(1 . 2) (mem-aref p '(:struct struct-pair) 1) '(3 . 4)) (values (mem-aref p '(:struct struct-pair) 0) (mem-aref p '(:struct struct-pair) 1))) (3 . 4) (213829 . 0) (with-foreign-object (p '(:struct struct-pair) 2) (setf (mem-aref p '(:struct struct-pair) 0) '(1 . 2) (mem-aref p '(:struct struct-pair) 1) '(3 . 4)) (values (mem-aref p '(:struct struct-pair) 0) (mem-aref p '(:struct struct-pair) 1))) (3 . 4) (425347 . 0)
parent
a227e3be
Please register or sign in to comment