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

PropertyMapWrapper.equals should compare className

XMLWordPrintable

    • b70
    • generic
    • generic

        PropertyMapWrapper is a class that implements equals and hashCode on property maps to allow for reuse of maps. It currently just compares properties, but not the owning object's class. If a property map is used with different owner classes accessing any field property will result in a ClassCastException.

        I noticed this while working on JDK-8077149, but the code that triggers the ClassCastException will not be part of the fix so I'm filing a separate bug.

              hannesw Hannes Wallnoefer
              hannesw Hannes Wallnoefer
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: