def modified_lines_from_udiff(udiff):
chunks = re.split('<STR_LIT>', udiff)[<NUM_LIT:1>:]<EOL>line_numbers = re.findall('<STR_LIT>', udiff)<EOL>line_numbers = list(map(int, line_numbers))<EOL>for c, start in zip(chunks, line_numbers):<EOL><INDENT>ilines = enumerate((line for line in c.splitlines()<EOL>if not line.startswith('<STR_LIT:->')),<EOL>start=start)<EOL>added_lines = [i for i, line in ilines if line.startswith('<STR_LIT:+>')]<EOL>if added_lines:<EOL><INDENT>yield (added_lines[<NUM_LIT:0>], added_lines[-<NUM_LIT:1>])<EOL><DEDENT><DEDENT>
Extract from a udiff an iterator of tuples of (start, end) line
    numbers.