equal
deleted
inserted
replaced
2933 getfile = util.lrucachefunc(repo.file) |
2933 getfile = util.lrucachefunc(repo.file) |
2934 |
2934 |
2935 def matchlines(body): |
2935 def matchlines(body): |
2936 begin = 0 |
2936 begin = 0 |
2937 linenum = 0 |
2937 linenum = 0 |
2938 while True and begin < len(body): |
2938 while begin < len(body): |
2939 match = regexp.search(body, begin) |
2939 match = regexp.search(body, begin) |
2940 if not match: |
2940 if not match: |
2941 break |
2941 break |
2942 mstart, mend = match.span() |
2942 mstart, mend = match.span() |
2943 linenum += body.count('\n', begin, mstart) + 1 |
2943 linenum += body.count('\n', begin, mstart) + 1 |