Function | array_constructor_callback |
Callback to provide an accurate signature for the ctypes.Array constructor. |
Function | array_getitem_callback |
Callback to provide an accurate return type for ctypes.Array.__getitem__. |
Function | array_iter_callback |
Callback to provide an accurate return type for ctypes.Array.__iter__. |
Function | array_raw_callback |
Callback to provide an accurate type for ctypes.Array.raw. |
Function | array_setitem_callback |
Callback to provide an accurate signature for ctypes.Array.__setitem__. |
Function | array_value_callback |
Callback to provide an accurate type for ctypes.Array.value. |
Function | _autoconvertible_to_cdata |
Get a type that is compatible with all types that can be implicitly converted to the given CData type. |
Function | _autounboxed_cdata |
Get the auto-unboxed version of a CData type, if applicable. |
Function | _find_simplecdata_base_arg |
Try to find a parametrized _SimpleCData in tp's bases and return its single type argument. |
Function | _get_array_element_type |
Get the element type of the Array type tp, or None if not specified. |
Function | _get_bytes_type |
Return the type corresponding to bytes on the current Python version. |
Function | _get_text_type |
Return the type corresponding to Text on the current Python version. |
Parameters | |
ctx:mypy.plugin.FunctionContext | Undocumented |
Returns | |
Type | Undocumented |
Parameters | |
ctx:mypy.plugin.MethodContext | Undocumented |
Returns | |
Type | Undocumented |
Parameters | |
ctx:mypy.plugin.MethodContext | Undocumented |
Returns | |
Type | Undocumented |
Parameters | |
ctx:mypy.plugin.AttributeContext | Undocumented |
Returns | |
Type | Undocumented |
Parameters | |
ctx:mypy.plugin.MethodSigContext | Undocumented |
Returns | |
CallableType | Undocumented |
Parameters | |
ctx:mypy.plugin.AttributeContext | Undocumented |
Returns | |
Type | Undocumented |
Get a type that is compatible with all types that can be implicitly converted to the given CData type.
Examples: * c_int -> Union[c_int, int] * c_char_p -> Union[c_char_p, bytes, int, NoneType] * MyStructure -> MyStructure
Parameters | |
tp:Type | Undocumented |
api:mypy.plugin.CheckerPluginInterface | Undocumented |
Returns | |
Type | Undocumented |
Get the auto-unboxed version of a CData type, if applicable.
For direct _SimpleCData subclasses, the only type argument of _SimpleCData in the bases list is returned. For all other CData types, including indirect _SimpleCData subclasses, tp is returned as-is.
Parameters | |
tp:Type | Undocumented |
Returns | |
ProperType | Undocumented |
Try to find a parametrized _SimpleCData in tp's bases and return its single type argument.
None is returned if _SimpleCData appears nowhere in tp's (direct or indirect) bases.
Parameters | |
tp:Instance | Undocumented |
api:mypy.plugin.CheckerPluginInterface | Undocumented |
Returns | |
Optional[ | Undocumented |
Parameters | |
tp:Type | Undocumented |
Returns | |
Optional[ | Undocumented |
Return the type corresponding to bytes on the current Python version.
This is bytes in Python 3, and str in Python 2.
Parameters | |
api:mypy.plugin.CheckerPluginInterface | Undocumented |
Returns | |
Instance | Undocumented |
Return the type corresponding to Text on the current Python version.
This is str in Python 3, and unicode in Python 2.
Parameters | |
api:mypy.plugin.CheckerPluginInterface | Undocumented |
Returns | |
Instance | Undocumented |