if (expr.match(stream, mymatch)) { mymatch.end[0] = mymatch.index; mymatch.finish(stream); stream.move(mymatch.toString().length()); offset += mymatch.toString().length(); buffer = mymatch.substituteInto(replace); bufpos = 1; // This is prone to infinite loops if replace string turns out empty. if (buffer.length() > 0) { return buffer.charAt(0);
if (expr.match(stream,mymatch)) { mymatch.end[0] = mymatch.index; mymatch.finish(stream); stream.move(mymatch.toString().length()); offset += mymatch.toString().length(); buffer = mymatch.substituteInto(replace); bufpos = 1; if (buffer.length() > 0) { return buffer.charAt(0);
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/gnu/regexp/REFilterInputStream.java File path: /jEdit-4.2/src/gnu/regexp/REFilterReader.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
if (expr.match(stream, mymatch)) {
1
if (expr.match(stream,mymatch)) {
2
      mymatch.end[0] = mymatch.index;
2
      mymatch.end[0] = mymatch.index;
3
      mymatch.finish(stream);
3
      mymatch.finish(stream);
4
      stream.move(mymatch.toString().length());
4
      stream.move(mymatch.toString().length());
5
      offset += mymatch.toString().length();
5
      offset += mymatch.toString().length();
6
      buffer = mymatch.substituteInto(replace);
6
      buffer = mymatch.substituteInto(replace);
7
      bufpos = 1;
7
      bufpos = 1;
8
      // This is prone to infinite loops if replace string turns out empty.
9
      if (buffer.length() > 0) {
8
      if (buffer.length() > 0) {
10
	  return buffer.charAt(0);
9
	  return buffer.charAt(0);
11
      
10
      
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