if (other instanceof RubyBignum) {
return value.compareTo(((RubyBignum)other).value);
}
return (int)coerceCmp(getRuntime().getCurrentContext(), "<=>", other).convertToInteger().getLongValue();
if (arg0 instanceof Variable) {
return _name.compareTo(((Variable)arg0)._name);
}
return 0;
Clone fragments detected by clone detection tool
File path: /jruby-1.4.0/src/org/jruby/RubyBignum.java
|
|
File path: /jruby-1.4.0/src/org/jruby/compiler/ir/operands/Variable.java
|
Method name: int compareTo(IRubyObject)
|
|
Method name: int compareTo(Object)
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | if (other instanceof RubyBignum) {↵ | | 1 | if (arg0 instanceof Variable) {↵
|
2 | return value.compareTo(((RubyBignum)other).value);↵ | | 2 | return _name.compareTo(((Variable)arg0)._name);↵
|
3 | }↵ | | 3 | }↵
|
4 | return (int)coerceCmp(getRuntime().getCurrentContext(), "<=>", other).convertToInteger().getLongValue(); | | 4 | return 0;
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |