def _CompareFields(field, other_field):
field_attrs = _GetFieldAttributes(field)<EOL>other_field_attrs = _GetFieldAttributes(other_field)<EOL>if field_attrs != other_field_attrs:<EOL><INDENT>return False<EOL><DEDENT>return field.__class__ == other_field.__class__<EOL>
Checks if two ProtoRPC fields are "equal".

    Compares the arguments, rather than the id of the elements (which is
    the default __eq__ behavior) as well as the class of the fields.

    Args:
      field: A ProtoRPC message field to be compared.
      other_field: A ProtoRPC message field to be compared.

    Returns:
      Boolean indicating whether the fields are equal.