File path: /jruby-1.4.0/src/org/jruby/runtime/callsite/SuperCallSite.java | File path: /jruby-1.4.0/src/org/jruby/runtime/callsite/SuperCallSite.java | |||
Method name: IRubyObject callBlock(ThreadContext, IRubyObject, IRubyObject, Block)
|
Method name: IRubyObject call(ThreadContext, IRubyObject, IRubyObject, IRubyObject)
|
|||
Number of AST nodes: 7 | Number of AST nodes: 7 | |||
1 | RubyModule klazz = context.getFrameKlazz();↵ | 1 | RubyModule klazz = context.getFrameKlazz();↵ | |
2 | String name = context.getFrameName();↵ | 2 | String name = context.getFrameName();↵ | |
3 | RubyClass selfType = pollAndGetClass(context, self, klazz, name);↵ | 3 | RubyClass selfType = pollAndGetClass(context, self, klazz, name);↵ | |
4 | CacheEntry myCache = cache;↵ | 4 | CacheEntry myCache = cache;↵ | |
5 | if (name == lastName && selfType != null && myCache.typeOk(selfType)) {↵ | 5 | if (name == lastName && selfType != null && myCache.typeOk(selfType)) {↵ | |
6 | return myCache.method.call(context, self, selfType, name, block);↵ | 6 | return myCache.method.call(context, self, selfType, name, arg1);↵ | |
7 | }↵ | 7 | }↵ | |
8 | return cacheAndCall(caller, selfType, block, context, self, name); | 8 | return cacheAndCall(caller, selfType, context, self, name, arg1); | |
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.4 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 15 |
Number of mapped statements | 7 |
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) | 7.9 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | RubyModule klazz = context.getFrameKlazz(); | 1 | RubyModule klazz = context.getFrameKlazz(); | |||||||||||||||
2 | String name = context.getFrameName(); | 2 | String name = context.getFrameName(); | |||||||||||||||
3 | RubyClass selfType = pollAndGetClass(context, self, klazz, name); | 3 | RubyClass selfType = pollAndGetClass(context, self, klazz, name); | |||||||||||||||
4 | CacheEntry myCache = cache; | 4 | CacheEntry myCache = cache; | |||||||||||||||
5 | if (name == lastName && selfType != null && myCache.typeOk(selfType)) | 5 | if (name == lastName && selfType != null && myCache.typeOk(selfType)) | |||||||||||||||
6 | return myCache.method.call(context, self, selfType, name, block); |
| 6 | return myCache.method.call(context, self, selfType, name, arg1); | ||||||||||||||
7 | return cacheAndCall(caller, selfType, block, context, self, name); |
| 7 | return cacheAndCall(caller, selfType, context, self, name, arg1); |
Row | Violation |
---|---|
1 | Type org.jruby.runtime.Block of variable block does not match with type org.jruby.runtime.builtin.IRubyObject of variable arg1 |
2 | Type org.jruby.runtime.Block of variable block does not match with type org.jruby.runtime.ThreadContext of variable context |