##// END OF EJS Templates
annotate: make pair take all parents to pair against...
Siddharth Agarwal -
r32484:c50f29b3 default
parent child Browse files
Show More
@@ -1044,8 +1044,8 b' class basefilectx(object):'
1044 if ready:
1044 if ready:
1045 visit.pop()
1045 visit.pop()
1046 curr = decorate(f.data(), f)
1046 curr = decorate(f.data(), f)
1047 curr = _annotatepair([hist[p] for p in pl], curr, diffopts)
1047 for p in pl:
1048 for p in pl:
1048 curr = _annotatepair(hist[p], curr, diffopts)
1049 if needed[p] == 1:
1049 if needed[p] == 1:
1050 del hist[p]
1050 del hist[p]
1051 del needed[p]
1051 del needed[p]
@@ -1073,8 +1073,12 b' class basefilectx(object):'
1073 c = visit.pop(max(visit))
1073 c = visit.pop(max(visit))
1074 yield c
1074 yield c
1075
1075
1076 def _annotatepair(parent, child, diffopts):
1076 def _annotatepair(parents, child, diffopts):
1077 blocks = mdiff.allblocks(parent[1], child[1], opts=diffopts)
1077 pblocks = [(parent, mdiff.allblocks(parent[1], child[1], opts=diffopts))
1078 for parent in parents]
1079 # Mercurial currently prefers p2 over p1 for annotate.
1080 # TODO: change this?
1081 for parent, blocks in pblocks:
1078 for (a1, a2, b1, b2), t in blocks:
1082 for (a1, a2, b1, b2), t in blocks:
1079 # Changed blocks ('!') or blocks made only of blank lines ('~')
1083 # Changed blocks ('!') or blocks made only of blank lines ('~')
1080 # belong to the child.
1084 # belong to the child.
General Comments 0
You need to be logged in to leave comments. Login now