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

Compiler confused by parenthesized "this" in final fields assignments

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P4
    • 11
    • 8-pool, 9, 10, 11
    • tools
    • None
    • b18

    Backports

      Description

        The following code fails:

        class Unassigned {
          final int x;

          Unassigned() {
            (this).x = 1;
          }
        }

        While removing parentheses make it working.

        Attachments

          Issue Links

            Activity

              People

                mcimadamore Maurizio Cimadamore
                mcimadamore Maurizio Cimadamore
                Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: