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

Compile-time error in the case of ((Integer[] & Serializable)new Integer[1]).getClass()

    Details

    • Subcomponent:
    • Introduced In Build:
      b112
    • Resolved In Build:
      b117
    • Verification:
      Not verified

      Backports

        Description

        The following tests started to fail in 112 after changes corresponding to JDK-8021339 resolving with following compile-time error:

        Error: java: cannot find symbol
          symbol: method getClass()

        while attempting to cast array to intersection of array and some interface and call getClass after casting

        Affected tests:
        lang/LMBD/lmbd118/lmbd11803m141/lmbd11803m141_rt.html
        lang/LMBD/lmbd118/lmbd11803m341/lmbd11803m341_rt.html
        lang/LMBD/lmbd118/lmbd11803m03/lmbd11803m03_rt.html
        lang/LMBD/lmbd118/lmbd11803m33/lmbd11803m33_rt.html
        lang/LMBD/lmbd118/lmbd11803m13/lmbd11803m13_rt.html

        Please find the attached a sample of a code reproducing above-mentioned behavior

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  emc Eric Mccorkle
                  Reporter:
                  ostrizhe Olga Strizhenko (Inactive)
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  6 Start watching this issue

                  Dates

                  • Due:
                    Created:
                    Updated:
                    Resolved: