Skip to content

Commit

Permalink
Extra fix for lcss needed
Browse files Browse the repository at this point in the history
  • Loading branch information
janmroczkowski committed Dec 8, 2017
1 parent cf187c8 commit 479e6cf
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/goto-diff/unified_diff.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,8 @@ unified_difft::differencest unified_difft::lcss(
{
differences.push_back(differencet::NEW);
--j;
--new_rit;
if(new_goto_program.instructions.begin()!=new_rit)
--new_rit;
}
else if(j == 0)
{
Expand All @@ -273,15 +274,18 @@ unified_difft::differencest unified_difft::lcss(
{
differences.push_back(differencet::SAME);
--i;
--old_rit;
if(old_goto_program.instructions.begin()!=old_rit)
--old_rit;
--j;
--new_rit;
if(new_goto_program.instructions.begin()!=new_rit)
--new_rit;
}
else if(lcss_matrix[i][j - 1] < lcss_matrix[i][j])
{
differences.push_back(differencet::DELETED);
--i;
--old_rit;
if(old_goto_program.instructions.begin()!=old_rit)
--old_rit;
}
else
{
Expand Down

0 comments on commit 479e6cf

Please sign in to comment.