module documentation
(source)

Astroid hooks for ctypes module.

Inside the ctypes module, the value class is defined inside the C coded module _ctypes. Thus astroid doesn't know that the value member is a builtin type among float, int, bytes or str.

Function enrich​_ctypes​_redefined​_types No summary
def enrich_ctypes_redefined_types(): (source)
For each ctypes redefined types, overload 'value' and '_type_' members definition. Overloading 'value' is mandatory otherwise astroid cannot infer the correct type for it. Overloading '_type_' is necessary because the class definition made here replaces the original one, in which '_type_' member is defined. Luckily those original class definitions are very short and contain only the '_type_' member definition.