Uneccesary String object created in java.util.Properties.java line 203

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P4
    • 1.4.0
    • Affects Version/s: 1.3.0
    • Component/s: core-libs
    • beta
    • generic
    • generic
    • Verified



      Name: yyT116575 Date: 01/18/2001


      java version "1.3.0"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
      Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)

      In java.util.Properties, line 203 marks the statement:

      nextLine = new String("");

      I am pretty sure that this is a creating 2 new String objects (one via the
      constructor and one via the object literal) where only 1 is needed. Since
      java.util.Properties is so heavily used I figured it might be worthwhile to
      bring this to your attention.
      (Review ID: 115398)
      ======================================================================

            Assignee:
            Michael Mccloskey (Inactive)
            Reporter:
            Yung-ching Young (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: