Re-examine Integer.parseInt and Long.parseLong methods

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • 9
    • Affects Version/s: 9
    • Component/s: core-libs
    • b31
    • Verified

        The parseInt and parseLong methods introduced by JDK-8041972 are error prone due to the sequence of parameters with the same type and the ordering. This bug requests that these methods be re-examined. Specifically:

        1. Consider dropping parseInt/parseLong(CharSequence, int radix, int beginIndex). It's not clear that there is a strong use-case for these methods.

        2. Change the ordering of parseInt/parseLong(CharSequence, int radix, int beginIndex, int endIndex) so that the begin/endIndex are after the CS, the radix at the end.

              Assignee:
              Claes Redestad
              Reporter:
              Alan Bateman
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: