try { if (index != -1) { br.reset(); } int i = br.read(); br.mark(bufsize); if (i == -1) { end = 1; cached = OUT_OF_BOUNDS; return false; } cached = (char) i; index = 1; } catch (IOException e) { e.printStackTrace(); cached = OUT_OF_BOUNDS; return false;
try { if (index != -1) { br.reset(); } int i = br.read(); br.mark(bufsize); if (i == -1) { end = 1; cached = OUT_OF_BOUNDS; return false; } // convert the byte read into a char cached = (char) i; index = 1; } catch (IOException e) { e.printStackTrace(); cached = OUT_OF_BOUNDS; return false;
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/gnu/regexp/CharIndexedInputStream.java File path: /jEdit-4.2/src/gnu/regexp/CharIndexedReader.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
try {
1
try {
2
	    if (index != -1) {
2
	    if (index != -1) {
3
		br.reset();
3
		br.reset();
4
	    }
4
	    }
5
	    int i = br.read();
5
	    int i = br.read();
6
	    br.mark(bufsize);
6
	    br.mark(bufsize);
7
	    if (i == -1) {
7
	    if (i == -1) {
8
		end = 1;
8
		end = 1;
9
		cached = OUT_OF_BOUNDS;
9
		cached = OUT_OF_BOUNDS;
10
		return false;
10
		return false;
11
	    }
11
	    }
12
	    // convert the byte read into a char
12
	    cached = (char) i;
13
	    cached = (char) i;
13
	    index = 1;
14
	    index = 1;
14
	} catch (IOException e) { 
15
	} catch (IOException e) { 
15
	    e.printStackTrace();
16
	    e.printStackTrace();
16
	    cached = OUT_OF_BOUNDS;
17
	    cached = OUT_OF_BOUNDS;
17
	    return false; 
18
	    return false; 
18
	
19
	
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0