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

Diff of /classpath/java/lang/String.java

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

revision 1.42 by ericb, Thu Mar 21 22:30:08 2002 UTC revision 1.43 by ericb, Mon Mar 25 00:32:33 2002 UTC
# Line 1415  public final class String implements Ser Line 1415  public final class String implements Ser
1415     */     */
1416    public char[] toCharArray()    public char[] toCharArray()
1417    {    {
1418      if (count == value.length)      // XXX ORP 1.0.9 crashes on (char[]) clone() during bootstrap, so we
1419        return (char[]) value.clone();      // omit this optimization for now.
1420        // if (count == value.length)
1421        //   return (char[]) value.clone();
1422      char[] copy = new char[count];      char[] copy = new char[count];
1423      System.arraycopy(value, offset, copy, 0, count);      System.arraycopy(value, offset, copy, 0, count);
1424      return copy;      return copy;

Legend:
Removed from v.1.42  
changed lines
  Added in v.1.43

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