Release Note: javac Accepts class Files With Any Number of Entries in RuntimeVisibleParameterAnnotations and RuntimeInvisibleParameterAnnotations Attributes

XMLWordPrintable

      The Java Virtual Machine Specification is permissive regarding the number of entries of the `RuntimeVisibleParameterAnnotations` and `RuntimeInvisibleParameterAnnotations` attributes in the `class` file format. The `javac` tool was less permissive, and was rejecting `class` files that had a different number of entries than `javac` expected.

      With JDK 24, this is fixed, and `javac` now accepts `class` files with any number of entries in the `RuntimeVisibleParameterAnnotations` and `RuntimeInvisibleParameterAnnotations` attributes. A compile-time warning is produced if the content of the attributes cannot be mapped to the corresponding method's parameters.

            Assignee:
            Jan Lahoda
            Reporter:
            Jan Lahoda
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: