runner.handleErrorFlush(output); if (showOutput) { super.handleErrorFlush(output); }
runner.handleFlush(output); if (showOutput) { super.handleFlush(output); }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/junit/JUnitTask.java
Method name: void handleErrorFlush(String) Method name: void handleFlush(String)
Number of AST nodes: 3 Number of AST nodes: 3
1
runner.handleErrorFlush(output);
1
runner.handleFlush(output);
2
            if (showOutput) {
2
            if (showOutput) {
3
                super.handleErrorFlush(output);
3
                super.handleFlush(output);
4
            }
4
            }
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.1
Clones locationClones are declared in the same class
Number of node comparisons6
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements3
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)0.7
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    2
    runner.handleErrorFlush(output);
    2
    runner.handleErrorFlush(output);
    2
    runner.handleFlush(output);
    Differences
    Expression1Expression2Difference
    handleErrorFlushhandleFlushMETHOD_INVOCATION_NAME_MISMATCH
    Preondition Violations
    Expression runner.handleErrorFlush(output) is a void method call, and thus it cannot be parameterized
    Expression runner.handleFlush(output) is a void method call, and thus it cannot be parameterized
    2
    runner.handleFlush(output);
    3
    if (showOutput)
    3
    if (showOutput)
    4
    super.handleErrorFlush(output);
    4
    super.handleErrorFlush(output);
    4
    super.handleFlush(output);
    Differences
    Expression1Expression2Difference
    handleErrorFlushhandleFlushMETHOD_INVOCATION_NAME_MISMATCH
    Preondition Violations
    Expression super.handleErrorFlush(output) is a void method call, and thus it cannot be parameterized
    Expression super.handleFlush(output) is a void method call, and thus it cannot be parameterized
    4
    super.handleFlush(output);
    Precondition Violations (4)
    Row Violation
    1Expression runner.handleErrorFlush(output) is a void method call, and thus it cannot be parameterized
    2Expression runner.handleFlush(output) is a void method call, and thus it cannot be parameterized
    3Expression super.handleErrorFlush(output) is a void method call, and thus it cannot be parameterized
    4Expression super.handleFlush(output) is a void method call, and thus it cannot be parameterized