def compute_all_type_links(ltypes):
    """ Compute all links between the different data types.

    Args:
        ltypes: List of all types
    """
    nbtypes = len(ltypes)
    for i, tp in enumerate(ltypes):
        tp.id = i
    for tp1 in ltypes:
        tp1.kind_of_types = tuple(map(lambda tp2: tp2.base_type in tp1.
            higher_types, ltypes))
    for tp1 in ltypes:
        ctypes = [None] * nbtypes
        for tp2 in ltypes:
            ct = tp1._compute_common_type(tp2)
            if ct is not None:
                ctypes[tp2.id] = ct
        tp1.common_types = tuple(ctypes)
