Mercurial > hg
comparison mercurial/mdiff.py @ 361:88268aa2b8d2
Fix another sortdiff cornercase
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Fix another sortdiff cornercase
manifest hash: 32b2d1750689c561c9471fb68a9f3571364399cb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCsL6AywK+sNU5EO8RAhaeAJ4zw18vo4oGTvymplKb7olKEeg0aQCfVxX1
2o/PcrE6EeboHpQn5E0Wb/Y=
=eENW
-----END PGP SIGNATURE-----
author | mpm@selenic.com |
---|---|
date | Wed, 15 Jun 2005 15:49:20 -0800 |
parents | 27d08c0c2a7e |
children | 8f8bb77d560e |
comparison
equal
deleted
inserted
replaced
360:10519e4cbd02 | 361:88268aa2b8d2 |
---|---|
56 | 56 |
57 if la > am: | 57 if la > am: |
58 yield (am, bm, la - am) # return a match | 58 yield (am, bm, la - am) # return a match |
59 | 59 |
60 # skip mismatched lines from b | 60 # skip mismatched lines from b |
61 while lb < lenb and b[lb] < a[la]: | 61 while la < lena and lb < lenb and b[lb] < a[la]: |
62 lb += 1 | 62 lb += 1 |
63 | 63 |
64 if lb >= lenb: | 64 if lb >= lenb: |
65 break | 65 break |
66 | 66 |
67 # skip mismatched lines from a | 67 # skip mismatched lines from a |
68 while la < lena and b[lb] > a[la]: | 68 while la < lena and lb < lenb and b[lb] > a[la]: |
69 la += 1 | 69 la += 1 |
70 | 70 |
71 if la >= lena: | 71 if la >= lena: |
72 break | 72 break |
73 | 73 |