[pypy-issue] [issue858] Can't create a ctypes pointer to a bool:

Alex Gaynor tracker at bugs.pypy.org
Sat Sep 3 05:16:19 CEST 2011

New submission from Alex Gaynor <alex.gaynor at gmail.com>:

>>>> import ctypes
>>>> ctypes.c_bool
<class 'ctypes.c_bool'>
>>>> ctypes.POINTER(ctypes.c_bool)
Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/home/alex/projects/pypy/lib_pypy/_ctypes/pointer.py", line 179, in 
    {'_type_': cls})
  File "/home/alex/projects/pypy/lib_pypy/_ctypes/pointer.py", line 31, in 
    self.set_type(obj, typedict['_type_'])
  File "/home/alex/projects/pypy/lib_pypy/_ctypes/pointer.py", line 70, in 
    self._ffiargtype = _ffi.types.Pointer(TP.get_ffi_argtype())
  File "/home/alex/projects/pypy/lib_pypy/_ctypes/basics.py", line 57, in 
    self._ffiargtype = _shape_to_ffi_type(self._ffiargshape)
  File "/home/alex/projects/pypy/lib_pypy/_ctypes/basics.py", line 204, in 
    assert False, 'unknown shape %s' % (shape,)
AssertionError: unknown shape ?

messages: 3069
nosy: agaynor, pypy-issue
priority: bug
status: unread
title: Can't create a ctypes pointer to a bool:

PyPy bug tracker <tracker at bugs.pypy.org>

More information about the pypy-issue mailing list