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

[lworld] add missing tests for functional interfaces

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • repo-valhalla
    • repo-valhalla
    • tools

      On section: 9.8 Functional Interfaces of [1] we have this assertion:

       * A functional interface is an interface that is not declared with one of the modifiers sealed, identity, or value...

      but this should apply too to functional interfaces which are not explicitly declared with the `identity` modifier. So this code should not be accepted:

          identity interface I {
              void m();
          }

          @FunctionalInterface
          interface J extends I {}

      [1] http://cr.openjdk.java.net/~dlsmith/jep8277163/jep8277163-20220519/specs/value-objects-jls.html#jls-9.8

            vromero Vicente Arturo Romero Zaldivar
            vromero Vicente Arturo Romero Zaldivar
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: