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 | if (jrubyMethod.alias().length > 0) {↵ | 1 | if (jrubyMethod.alias().length > 0) {↵ | |
2 | for (String alias : jrubyMethod.alias()) {↵ | 2 | for (String alias : jrubyMethod.alias()) {↵ | |
3 | out.println(" metaClass.defineAlias(\"" + alias + "\", \"" + baseName + "\");");↵ | 3 | out.println(" cls.defineAlias(\"" + alias + "\", \"" + baseName + "\");");↵ | |
4 | }↵ | 4 | }↵ | |
5 | } | 5 |
| |
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 | 5 |
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 | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
9 | if (jrubyMethod.alias().length > 0) | 19 | if (jrubyMethod.alias().length > 0) | |||||||||||
10 | for (String alias : jrubyMethod.alias()) | 20 | for (String alias : jrubyMethod.alias()) | |||||||||||
11 | out.println(" metaClass.defineAlias(\"" + alias + "\", \"" + baseName + "\");"); |
| 21 | out.println(" cls.defineAlias(\"" + alias + "\", \"" + baseName + "\");"); |
Row | Violation |
---|