Long.valueOf(String) should cache

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P5
    • None
    • Affects Version/s: 5.0
    • Component/s: core-libs

      A DESCRIPTION OF THE REQUEST :
      The source code for Long.valueOf(String) shows that it returns new Long(parseLong(...)). It really should return Long.valueOf(parseLong(...)) so that it can take advantage of the cache.

      JUSTIFICATION :
      More efficient.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      See above
      ACTUAL -
      See above

      ---------- BEGIN SOURCE ----------
      None -- see source code for java.lang.Long
      ---------- END SOURCE ----------

            Assignee:
            Joe Darcy
            Reporter:
            Nelson Dcosta (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: