hgkw/keyword.py
changeset 1042 91e083fab1a3
parent 998 cc54b798aca4
child 1073 bc8e57c1ae32
equal deleted inserted replaced
1040:15aa105f81e2 1042:91e083fab1a3
   678     def kwfilectx_cmp(orig, self, fctx):
   678     def kwfilectx_cmp(orig, self, fctx):
   679         # keyword affects data size, comparing wdir and filelog size does
   679         # keyword affects data size, comparing wdir and filelog size does
   680         # not make sense
   680         # not make sense
   681         if (fctx._filerev is None and
   681         if (fctx._filerev is None and
   682             (self._repo._encodefilterpats or
   682             (self._repo._encodefilterpats or
   683              kwt.match(fctx.path()) and not 'l' in fctx.flags()) or
   683              kwt.match(fctx.path()) and not 'l' in fctx.flags() or
       
   684              self.size() - 4 == fctx.size()) or
   684             self.size() == fctx.size()):
   685             self.size() == fctx.size()):
   685             return self._filelog.cmp(self._filenode, fctx.data())
   686             return self._filelog.cmp(self._filenode, fctx.data())
   686         return True
   687         return True
   687 
   688 
   688     extensions.wrapfunction(context.filectx, 'cmp', kwfilectx_cmp)
   689     extensions.wrapfunction(context.filectx, 'cmp', kwfilectx_cmp)