sline 315 combine-diff.c static void append_lost(struct sline *sline, int n, const char *line, int len) sline 325 combine-diff.c lline->prev = sline->plost.lost_tail; sline 329 combine-diff.c sline->plost.lost_head = lline; sline 330 combine-diff.c sline->plost.lost_tail = lline; sline 331 combine-diff.c sline->plost.len++; sline 343 combine-diff.c struct sline *sline; sline 344 combine-diff.c struct sline *lost_bucket; sline 366 combine-diff.c state->lost_bucket = &state->sline[state->nb]; sline 370 combine-diff.c state->lost_bucket = &state->sline[state->nb-1]; sline 372 combine-diff.c if (!state->sline[state->nb-1].p_lno) sline 373 combine-diff.c state->sline[state->nb-1].p_lno = sline 376 combine-diff.c state->sline[state->nb-1].p_lno[state->n] = state->ob; sline 386 combine-diff.c state->sline[state->lno-1].flag |= state->nmask; sline 394 combine-diff.c struct sline *sline, unsigned int cnt, int n, sline 417 combine-diff.c state.sline = sline; sline 437 combine-diff.c sline[lno].p_lno[n] = p_lno; sline 440 combine-diff.c if (sline[lno].plost.lost_head) { sline 441 combine-diff.c struct sline *sl = &sline[lno]; sline 450 combine-diff.c ll = sline[lno].lost; sline 456 combine-diff.c if (lno < cnt && !(sline[lno].flag & nmask)) sline 459 combine-diff.c sline[lno].p_lno[n] = p_lno; /* trailer */ sline 465 combine-diff.c static int interesting(struct sline *sline, unsigned long all_mask) sline 470 combine-diff.c return ((sline->flag & all_mask) || sline->lost); sline 473 combine-diff.c static unsigned long adjust_hunk_tail(struct sline *sline, sline 485 combine-diff.c if ((hunk_begin + 1 <= i) && !(sline[i-1].flag & all_mask)) sline 490 combine-diff.c static unsigned long find_next(struct sline *sline, sline 505 combine-diff.c ? !(sline[i].flag & mark) sline 506 combine-diff.c : (sline[i].flag & mark)) sline 513 combine-diff.c static int give_context(struct sline *sline, unsigned long cnt, int num_parent) sline 529 combine-diff.c i = find_next(sline, mark, 0, cnt, 0); sline 539 combine-diff.c if (!(sline[j].flag & mark)) sline 540 combine-diff.c sline[j].flag |= no_pre_delete; sline 541 combine-diff.c sline[j++].flag |= mark; sline 548 combine-diff.c j = find_next(sline, mark, i, cnt, 1); sline 553 combine-diff.c k = find_next(sline, mark, j, cnt, 0); sline 554 combine-diff.c j = adjust_hunk_tail(sline, all_mask, i, j); sline 561 combine-diff.c sline[j++].flag |= mark; sline 573 combine-diff.c sline[j++].flag |= mark; sline 578 combine-diff.c static int make_hunks(struct sline *sline, unsigned long cnt, sline 587 combine-diff.c if (interesting(&sline[i], all_mask)) sline 588 combine-diff.c sline[i].flag |= mark; sline 590 combine-diff.c sline[i].flag &= ~mark; sline 593 combine-diff.c return give_context(sline, cnt, num_parent); sline 603 combine-diff.c while (i <= cnt && !(sline[i].flag & mark)) sline 609 combine-diff.c if (!(sline[j].flag & mark)) { sline 616 combine-diff.c la = adjust_hunk_tail(sline, all_mask, sline 621 combine-diff.c if (sline[la].flag & mark) { sline 655 combine-diff.c unsigned long this_diff = sline[j].flag & all_mask; sline 656 combine-diff.c struct lline *ll = sline[j].lost; sline 685 combine-diff.c sline[j].flag &= ~mark; sline 690 combine-diff.c has_interesting = give_context(sline, cnt, num_parent); sline 694 combine-diff.c static void show_parent_lno(struct sline *sline, unsigned long l0, unsigned long l1, int n, unsigned long null_context) sline 696 combine-diff.c l0 = sline[l0].p_lno[n]; sline 697 combine-diff.c l1 = sline[l1].p_lno[n]; sline 723 combine-diff.c static void dump_sline(struct sline *sline, const char *line_prefix, sline 747 combine-diff.c while (lno <= cnt && !(sline[lno].flag & mark)) { sline 748 combine-diff.c if (hunk_comment_line(sline[lno].bol)) sline 749 combine-diff.c hunk_comment = sline[lno].bol; sline 756 combine-diff.c if (!(sline[hunk_end].flag & mark)) sline 775 combine-diff.c if (!(sline[j].flag & (mark-1))) sline 783 combine-diff.c show_parent_lno(sline, lno, hunk_end, i, null_context); sline 809 combine-diff.c struct sline *sl = &sline[lno++]; sline 849 combine-diff.c static void reuse_combine_diff(struct sline *sline, unsigned long cnt, sline 861 combine-diff.c struct lline *ll = sline->lost; sline 862 combine-diff.c sline->p_lno[i] = sline->p_lno[j]; sline 868 combine-diff.c if (sline->flag & jmask) sline 869 combine-diff.c sline->flag |= imask; sline 870 combine-diff.c sline++; sline 873 combine-diff.c sline->p_lno[i] = sline->p_lno[j]; sline 978 combine-diff.c struct sline *sline; /* survived lines */ sline 1118 combine-diff.c sline = xcalloc(cnt+2, sizeof(*sline)); sline 1119 combine-diff.c sline[0].bol = result; sline 1122 combine-diff.c sline[lno].len = cp - sline[lno].bol; sline 1125 combine-diff.c sline[lno].bol = cp + 1; sline 1129 combine-diff.c sline[cnt-1].len = result_size - (sline[cnt-1].bol - result); sline 1137 combine-diff.c sline[0].p_lno = xcalloc((cnt+2) * num_parent, sizeof(unsigned long)); sline 1139 combine-diff.c sline[lno+1].p_lno = sline[lno].p_lno + num_parent; sline 1146 combine-diff.c reuse_combine_diff(sline, cnt, i, j); sline 1153 combine-diff.c &result_file, sline, sline 1158 combine-diff.c show_hunks = make_hunks(sline, cnt, num_parent, dense); sline 1163 combine-diff.c dump_sline(sline, line_prefix, cnt, num_parent, sline 1169 combine-diff.c if (sline[lno].lost) { sline 1170 combine-diff.c struct lline *ll = sline[lno].lost; sline 1178 combine-diff.c free(sline[0].p_lno); sline 1179 combine-diff.c free(sline);