parameters: (t)
docstring: Construct a dtype object from a ctypes type
docstring_summary: Construct a dtype object from a ctypes type
docstring_tokens: Construct a dtype object from a ctypes type
function: def dtype_from_ctypes_type(t):
      """
      Construct a dtype object from a ctypes type
      """
      if issubclass(t, _ctypes.Array):
          return _from_ctypes_array(t)
      elif issubclass(t, _ctypes._Pointer):
          raise TypeError("ctypes pointers have no dtype equivalent")
      elif issubclass(t, _ctypes.Structure):
          return _from_ctypes_structure(t)
      elif issubclass(t, _ctypes.Union):
          return _from_ctypes_union(t)
      elif isinstance(getattr(t, '_type_', None), str):
          return _from_ctypes_scalar(t)
      else:
          raise NotImplementedError(
              "Unknown ctypes type {}".format(t.__name__))
function_tokens: def dtype_from_ctypes_type ( t ) : if issubclass ( t , _ctypes . Array ) : return _from_ctypes_array ( t ) elif issubclass ( t , _ctypes . _Pointer ) : raise TypeError ( "ctypes pointers have no dtype equivalent" ) elif issubclass ( t , _ctypes . Structure ) : return _from_ctypes_structure ( t ) elif issubclass ( t , _ctypes . Union ) : return _from_ctypes_union ( t ) elif isinstance ( getattr ( t , '_type_' , None ) , str ) : return _from_ctypes_scalar ( t ) else : raise NotImplementedError ( "Unknown ctypes type {}" . format ( t . __name__ ) )