File path: /jruby-1.4.0/src/org/jruby/anno/AnnotationBinder.java | File path: /jruby-1.4.0/src/org/jruby/anno/AnnotationBinder.java | |||
Method name: void generateMethodAddCalls(MethodDeclaration, JRubyMethod)
|
Method name: void generateMethodAddCalls(MethodDeclaration, JRubyMethod)
|
|||
Number of AST nodes: 3 | Number of AST nodes: 3 | |||
1 | baseName = jrubyMethod.name()[0];↵ | 1 | baseName = jrubyMethod.name()[0];↵ | |
2 | for (String name : jrubyMethod.name()) {↵ | 2 | for (String name : jrubyMethod.name()) {↵ | |
3 | out.println(" metaClass.addMethodAtBootTimeOnly(\"" + name + "\", javaMethod);");↵ | 3 | out.println(" cls.addMethodAtBootTimeOnly(\"" + name + "\", javaMethod);");↵ | |
4 | } | 4 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.3 |
Clones location | Clones are in the same method |
Number of node comparisons | 6 |
Number of mapped statements | 3 |
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) | 0.7 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
6 | baseName = jrubyMethod.name()[0]; | 16 | baseName = jrubyMethod.name()[0]; | |||||||||||
7 | for (String name : jrubyMethod.name()) | 17 | for (String name : jrubyMethod.name()) | |||||||||||
8 | out.println(" metaClass.addMethodAtBootTimeOnly(\"" + name + "\", javaMethod);"); |
| 18 | out.println(" cls.addMethodAtBootTimeOnly(\"" + name + "\", javaMethod);"); |
Row | Violation |
---|