docs: def _initialize_references(model_class, name, bases, attrs):
      """Stores the list of reference field descriptors of a model."""
      model_class._references = {}
      h = {}
      deferred = []
      for k, v in attrs.iteritems():
          if isinstance(v, ReferenceField):
              model_class._references[k] = v
              v.name = v.name or k
              att = Attribute(name=v.attname)
              h[v.attname] = att
              setattr(model_class, v.attname, att)
              refd = _initialize_referenced(model_class, v)
              if refd:
                  deferred.append(refd)
      attrs.update(h)
      return deferred