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: 9 | Number of AST nodes: 9 | |||
1 | if (REUtil.isHighSurrogate(ch) && matchStart+1 < con.limit) {↵ | 1 | if (REUtil.isHighSurrogate(ch) && matchStart+1 < con.limit) {↵ | |
2 | ch = REUtil.composeFromSurrogates(ch, target .charAt( matchStart+1 ) );↵ | 2 | ch = REUtil.composeFromSurrogates(ch, target .setIndex( matchStart+1 ) );↵ | |
3 | if (!range.match(ch)) continue;↵ | 3 | if (!range.match(ch)) continue;↵ | |
4 | } else {↵ | 4 | } else {↵ | |
5 | if (!range.match(ch)) {↵ | 5 | if (!range.match(ch)) {↵ | |
6 | char ch1 = Character.toUpperCase((char)ch);↵ | 6 | char ch1 = Character.toUpperCase((char)ch);↵ | |
7 | if (!range.match(ch1))↵ | 7 | if (!range.match(ch1))↵ | |
8 | if (!range.match(Character.toLowerCase(ch1)))↵ | 8 | if (!range.match(Character.toLowerCase(ch1)))↵ | |
9 | continue;↵ | 9 | continue;↵ | |
10 | }↵ | 10 | }↵ | |
11 | } | 11 |
| |
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) | 1.0 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 20 |
Number of mapped statements | 9 |
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) | 2.3 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
68 | if (REUtil.isHighSurrogate(ch) && matchStart + 1 < con.limit) | 65 | if (REUtil.isHighSurrogate(ch) && matchStart + 1 < con.limit) | |||||||||||||||||
69 | ch = REUtil.composeFromSurrogates(ch, target.charAt(matchStart + 1)); |
| 66 | ch = REUtil.composeFromSurrogates(ch, target.setIndex(matchStart + 1)); | ||||||||||||||||
70 | if (!range.match(ch)) | 67 | if (!range.match(ch)) | |||||||||||||||||
71 | continue; |
| 68 | continue; | ||||||||||||||||
else | else | |||||||||||||||||||
72 | if (!range.match(ch)) | 69 | if (!range.match(ch)) | |||||||||||||||||
73 | char ch1 = Character.toUpperCase((char)ch); | 70 | char ch1 = Character.toUpperCase((char)ch); | |||||||||||||||||
74 | if (!range.match(ch1)) | 71 | if (!range.match(ch1)) | |||||||||||||||||
75 | if (!range.match(Character.toLowerCase(ch1))) | 72 | if (!range.match(Character.toLowerCase(ch1))) | |||||||||||||||||
76 | continue; |
| 73 | continue; |
Row | Violation |
---|---|
1 | Expression target.charAt(matchStart + 1) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression target.setIndex(matchStart + 1) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Type java.lang.String of variable target does not match with type java.text.CharacterIterator of variable target |
4 | Statement continue; without innermost loop |
5 | Statement continue; without innermost loop |
6 | Statement continue; without innermost loop |
7 | Statement continue; without innermost loop |