/[classpath]/classpath/java/lang/StringBuffer.java
ViewVC logotype

Diff of /classpath/java/lang/StringBuffer.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.22 by mkoch, Thu May 22 07:17:07 2003 UTC revision 1.23 by bryce, Mon Sep 22 08:18:09 2003 UTC
# Line 567  public final class StringBuffer implemen Line 567  public final class StringBuffer implemen
567        throw new StringIndexOutOfBoundsException();        throw new StringIndexOutOfBoundsException();
568      if (len == 0)      if (len == 0)
569        return "";        return "";
570      // Share the char[] unless 3/4 empty.      // Share unless substring is smaller than 1/4 of the buffer.
571      shared = (len << 2) >= value.length;      if ((len << 2) >= value.length)
572          shared = true;
573      // Package constructor avoids an array copy.      // Package constructor avoids an array copy.
574      return new String(value, beginIndex, len, shared);      return new String(value, beginIndex, len, shared);
575    }    }

Legend:
Removed from v.1.22  
changed lines
  Added in v.1.23

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26