ArgumentType

Defines a general purpose ArgumentType so that we can easily manage complicated type specs The basic idea is to define a hierarchy of types that can then convert themselves down to a ctypes-style spec as well as a C++ argument spec so that we can enable SharedLibraryFunction to use either the basic ctypes FFI or a more efficient, but fragile system based off of extension modules. This will be explicitly overridden by the PrimitiveType, ArrayType and PointerType subclasses that provide the actual useable classes. I’d really live to be integrate with what’s in the typing module to be able to reuse that type-inference machinery

 

@property
ctypes_type(self): 

 

@property
cpp_type(self): 

 

@property
types(self): 

 

@property
dtypes(self): 

 

@property
typechar(self): 

 

isinstance(self, arg): 

 

cast(self, arg): 

 

c_cast(self, arg): 

Feedback

Examples

Templates

Documentation