File path: /jruby-1.4.0/src/org/jruby/RubyString.java | File path: /jruby-1.4.0/src/org/jruby/RubyString.java | |||
Method name: IRubyObject delete_bang19(ThreadContext, IRubyObject[])
|
Method name: IRubyObject count19(ThreadContext, IRubyObject[])
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | for (int i=1; i<args.length; i++) {↵ | 1 | for (int i = 1; i<args.length; i++) {↵ | |
2 | otherStr = args[i].convertToString();↵ | 2 | otherStr = args[i].convertToString();↵ | |
3 | enc = checkEncoding(otherStr);↵ | 3 | enc = checkEncoding(otherStr);↵ | |
4 | tables = otherStr.trSetupTable(runtime, squeeze, tables, false, enc);↵ | 4 | tables = otherStr.trSetupTable(runtime, table, tables, false, enc);↵ | |
5 | } | 5 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 16 |
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 2.1 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
8 | for (int i = 1; i < args.length; i++) | 8 | for (int i = 1; i < args.length; i++) | |||||||||||
9 | otherStr = args[i].convertToString(); | 9 | otherStr = args[i].convertToString(); | |||||||||||
10 | enc = checkEncoding(otherStr); | 10 | enc = checkEncoding(otherStr); | |||||||||||
11 | tables = otherStr.trSetupTable(runtime, squeeze, tables, false, enc); |
| 11 | tables = otherStr.trSetupTable(runtime, table, tables, false, enc); |
Row | Violation |
---|---|
1 | Clone fragment #1 returns variables enc, tables , while Clone fragment #2 returns variables enc, tables |