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

invokeinterface: Remove IAE for selection of non-public method

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 7, 8
    • specification
    • vm

      invokeinterface requires an IAE if the selected method is not public.

      invokevirtual performs no checks on the access of the selected method (although it skips over private methods).

      This distinction is unnecessary and arbitrary. It would probably be better to simply eliminate the access check for invokeinterface (and also change its behavior so that it skips private methods).

      The change would be fully compatible: it eliminates an error.

            dlsmith Dan Smith
            dlsmith Dan Smith
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: