if (asciiOnly) { ByteList tmp = bs.shallowDup(); tmp.encoding = USASCIIEncoding.INSTANCE; return tmp; }
if (cv == null) { Variable v = currScope.getNewVariable(); currScope.addInstr(new GET_CONST_Instr(v, s, name)); cv = v; }
Clone fragments detected by clone detection tool
File path: /jruby-1.4.0/src/org/jruby/RubyRegexp.java File path: /jruby-1.4.0/src/org/jruby/compiler/ir/IR_Builder.java
Method name: ByteList quote19(ByteList, boolean) Method name: Operand loadConst(IR_Scope, IR_Scope, String)
Number of AST nodes: 4 Number of AST nodes: 4
1
if (asciiOnly) {
1
if (cv == null) {
2
                ByteList tmp = bs.shallowDup();
2
            
3
                tmp.encoding = USASCIIEncoding.INSTANCE;
4
                return tmp;
5
    
3
Variable v = currScope.getNewVariable();
4
            currScope.addInstr(new GET_CONST_Instr(v, s, name));
5
            cv = v;
6
        }
6
        }
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in different classes
Number of node comparisons1