Comment #6 on issue 189 by ken...@google.com: Generated message __cmp__() in Python should consistently order generated messages
http://code.google.com/p/protobuf/issues/detail?id=189

I think most users would find that behavior surprising. Documenting the behavior isn't good enough -- developers will often make assumptions about things that seem
"obvious" without reading the docs.

Some problems with implementing comparison "correctly":

1) What is correct? Different people will have different answers. Should we compare each field in order? Which order? Declaration order, or field number order? Etc.
Different apps will have different needs.

2) If we ever implement unknown field retention in Python (as we have in C++ and
Java), how do we compare them?  Without knowing the type of the fields, any
comparison approach is arbitrary and possibly wrong.

--
You received this message because you are subscribed to the Google Groups "Protocol 
Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en.

Reply via email to