diff mercurial/filelog.py @ 11539:a463e3c50212 stable

cmp: document the fact that we return True if content is different This is similar to the __builtin__.cmp behaviour, but still not straightforward, as the dailylife meaning of a comparison usually is "find out if they are different".
author Nicolas Dumazet <nicdumz.commits@gmail.com>
date Fri, 09 Jul 2010 11:02:39 +0900
parents d8d1b56d4519
children 2370e270a29a
line wrap: on
line diff
--- a/mercurial/filelog.py	Fri Jul 09 11:59:48 2010 +0900
+++ b/mercurial/filelog.py	Fri Jul 09 11:02:39 2010 +0900
@@ -56,7 +56,10 @@
         return revlog.revlog.size(self, rev)
 
     def cmp(self, node, text):
-        """compare text with a given file revision"""
+        """compare text with a given file revision
+
+        returns True if text is different than what is stored.
+        """
 
         # for renames, we have to go the slow way
         if text.startswith('\1\n') or self.renamed(node):