File path: /emf-2.4.1/src/org/eclipse/emf/ecore/xml/type/internal/RegEx.java | File path: /emf-2.4.1/src/org/eclipse/emf/ecore/xml/type/internal/RegEx.java | |||
Method name: boolean matches(String, int, int, Match)
|
Method name: boolean matches(CharacterIterator, Match)
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | if (this.fixedString != null) {↵ | 1 | if (this.fixedString != null) {↵ | |
2 | int o = this.fixedStringTable.matches(target, con.start, con.limit);↵ | 2 | int o = this.fixedStringTable.matches(target, con.start, con.limit);↵ | |
3 | if (o < 0) {↵ | 3 | if (o < 0) {↵ | |
4 | //System.err.println("Non-match in fixed-string search.");↵ | 4 | //System.err.println("Non-match in fixed-string search.");↵ | |
5 | con.inuse = false;↵ | 5 | con.inuse = false;↵ | |
6 | return false;↵ | 6 | return false;↵ | |
7 | }↵ | 7 | }↵ | |
8 | } | 8 |
| |
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 | 13 |
Number of mapped statements | 5 |
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) | 1.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
41 | if (this.fixedString != null) | 38 | if (this.fixedString != null) | ||||||||||||
42 | int o = this.fixedStringTable.matches(target, con.start, con.limit); |
| 39 | int o = this.fixedStringTable.matches(target, con.start, con.limit); | |||||||||||
43 | if (o < 0) | 40 | if (o < 0) | ||||||||||||
44 | con.inuse = false; | 41 | con.inuse = false; | ||||||||||||
45 | return false; |
| 42 | return false; |
Row | Violation |
---|---|
1 | Type java.lang.String of variable target does not match with type java.text.CharacterIterator of variable target |
2 | Conditional return false; |
3 | Conditional return false; |