def resolve_common_type(parser, commontype):
    try:
        return _CACHE[commontype]
    except __HOLE__:
        cdecl = COMMON_TYPES.get(commontype, commontype)
        if not isinstance(cdecl, str):
            result, quals = cdecl, 0    # cdecl is already a BaseType
        elif cdecl in model.PrimitiveType.ALL_PRIMITIVE_TYPES:
            result, quals = model.PrimitiveType(cdecl), 0
        elif cdecl == 'set-unicode-needed':
            raise api.FFIError("The Windows type %r is only available after "
                               "you call ffi.set_unicode()" % (commontype,))
        else:
            if commontype == cdecl:
                raise api.FFIError("Unsupported type: %r.  Please file a bug "
                                   "if you think it should be." % (commontype,))
            result, quals = parser.parse_type_and_quals(cdecl)   # recursive

        assert isinstance(result, model.BaseTypeByIdentity)
        _CACHE[commontype] = result, quals
        return result, quals


# ____________________________________________________________
# extra types for Windows (most of them are in commontypes.c)
dataset/ETHPy150Open cloudera/hue/desktop/core/ext-py/cffi-1.5.2/cffi/commontypes.py/resolve_common_type