

def contribute_to_related_class(self, cls, related):
    if ((not self.rel.is_hidden()) and (not related.model._meta.swapped)):
        setattr(cls, related.get_accessor_name(), ManyRelatedObjectsDescriptor(related))
    self.m2m_column_name = curry(self._get_m2m_attr, related, 'column')
    self.m2m_reverse_name = curry(self._get_m2m_reverse_attr, related, 'column')
    self.m2m_field_name = curry(self._get_m2m_attr, related, 'name')
    self.m2m_reverse_field_name = curry(self._get_m2m_reverse_attr, self, 'name')
    get_m2m_rel = curry(self._get_m2m_attr, related, 'rel')
    self.m2m_target_field_name = (lambda : get_m2m_rel().field_name)
    get_m2m_reverse_rel = curry(self._get_m2m_reverse_attr, related, 'rel')
    self.m2m_reverse_target_field_name = (lambda : get_m2m_reverse_rel().field_name)

dataset/ETHPy150Open AppScale/appscale/AppServer/lib/django-1.5/django/db/models/fields/related.py ManyToManyField.contribute_to_related_class/VarMisuse@113/169 `related`->`self`