ptr_ = a.buffer_info() 这一行错了, 少了一个ptr_之间少可以个,

ptr_ = a.buffer_info() 这一行错了, 少了一个ptr_之间少可以个,
This commit is contained in:
Chyun
2022-12-01 18:06:44 +08:00
committed by GitHub
parent d82f16e6cb
commit cdbe30b3b5

View File

@@ -255,7 +255,7 @@
>>> a = array.array('d',[1,2,3])
>>> a
array('d', [1.0, 2.0, 3.0])
>>> ptr_ = a.buffer_info()
>>> ptr, _ = a.buffer_info()
>>> ptr
4298687200
>>> ctypes.cast(ptr, ctypes.POINTER(ctypes.c_double))