def _resnames_match(resnames, allowed_resnames):
    """
    Return true if one element in resnames matches
    one element in allowed_resnames.

    Parameters
    ----------
    resnames: `abc.iterable`
    allowed_resnames: `abc.iterable`
    """
    for resname in resnames:
        if resname in allowed_resnames:
           return True
    return False