while (ll_i != tmp) { j++; byte tmp2 = tmp; tmp = pos[j]; pos[j] = tmp2; }
while (ll_i != tmp) { j++; byte tmp2 = tmp; tmp = yy[j]; yy[j] = tmp2; }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/bzip2/CBZip2OutputStream.java File path: /apache-ant-1.7.0/src/org/apache/tools/bzip2/CBZip2OutputStream.java
Method name: void sendMTFValues2(int, int) Method name: void generateMTFValues()
Number of AST nodes: 5 Number of AST nodes: 5
1
while (ll_i != tmp) {
1
while (ll_i != tmp) {
2
                j++;
2
                j++;
3
                byte tmp2 = tmp;
3
                byte tmp2 = tmp;
4
                tmp = pos[j];
4
                tmp = yy[j];
5
                pos[j] = tmp2;
5
                yy[j] = tmp2;
6
            }
6
            }
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.2
Clones locationClones are declared in the same class
Number of node comparisons33
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements5
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)1.2
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    9
    while (ll_i != tmp)
    27
    while (ll_i != tmp)
    10
    j++;
    28
    j++;
    11
    byte tmp2 = tmp;
    29
    byte tmp2 = tmp;
    12
    tmp = pos[j];
    12
    tmp = pos[j];
    30
    tmp = yy[j];
    Differences
    Expression1Expression2Difference
    posyyVARIABLE_NAME_MISMATCH
    30
    tmp = yy[j];
    13
    pos[j] = tmp2;
    13
    pos[j] = tmp2;
    31
    yy[j] = tmp2;
    Differences
    Expression1Expression2Difference
    posyyVARIABLE_NAME_MISMATCH
    31
    yy[j] = tmp2;
    Precondition Violations (1)
    Row Violation
    1Clone fragment #1 returns variables tmp, j , while Clone fragment #2 returns variables tmp, j