parameters: (ctypeobj)
return_statement: return ty
docstring: Convert the given ctypes type to a Numba type.
docstring_summary: Convert the given ctypes type to a Numba type.
docstring_tokens: Convert the given ctypes type to a Numba type .
function: def from_ctypes(ctypeobj):
      """
      Convert the given ctypes type to a Numba type.
      """
      if ctypeobj is None:
          # Special case for the restype of void-returning functions
          return types.none
  
      assert isinstance(ctypeobj, type), ctypeobj
  
      def _convert_internal(ctypeobj):
          # Recursive helper
          if issubclass(ctypeobj, ctypes._Pointer):
              valuety = _convert_internal(ctypeobj._type_)
              if valuety is not None:
                  return types.CPointer(valuety)
          else:
              return _FROM_CTYPES.get(ctypeobj)
  
      ty = _convert_internal(ctypeobj)
      if ty is None:
          raise TypeError("Unsupported ctypes type: %s" % ctypeobj)
      return ty
function_tokens: def from_ctypes ( ctypeobj ) : if ctypeobj is None : # Special case for the restype of void-returning functions return types . none assert isinstance ( ctypeobj , type ) , ctypeobj def _convert_internal ( ctypeobj ) : # Recursive helper if issubclass ( ctypeobj , ctypes . _Pointer ) : valuety = _convert_internal ( ctypeobj . _type_ ) if valuety is not None : return types . CPointer ( valuety ) else : return _FROM_CTYPES . get ( ctypeobj ) ty = _convert_internal ( ctypeobj ) if ty is None : raise TypeError ( "Unsupported ctypes type: %s" % ctypeobj ) return ty