Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4966568

java.lang.NullPointerException: say which variable when multiple in the line

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • 1.4.2
    • hotspot
    • x86
    • linux



      Name: rmT116609 Date: 12/10/2003


      A DESCRIPTION OF THE REQUEST :
      if a java.lang.NullPointerException references a method with multiple variables in its signature, it would be very helpful if the exception would tell which one of them was the culprit!

      JUSTIFICATION :
      when the exception is thrown, it is known with variable is the culprit.
      Sharing this with the user would increase the speed of programming with Java even further

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      for example:

      java.lang.NullPointerException on line 123: variable "User"
      ACTUAL -
      java.lang.NullPointerException on line 123

      not knowing which variable is the culprit often leads to lengthy, wasteful searches
      (Incident Review ID: 230212)
      ======================================================================

            phh Paul Hohensee
            rmandalasunw Ranjith Mandala (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: