def _mangle_name(internal_name, class_name):
    """Transform *name* (which is assumed to be an "__internal" name)
    into a "_ClassName__internal" name.

    :param str internal_name: the assumed-to-be-"__internal" member name
    :param str class_name: the name of the class where *name* is defined
    :return: the transformed "_ClassName__internal" name
    :rtype: str

    """
    return "_%s%s" % (class_name.lstrip('_'), internal_name)