Ticket #121 (closed defect: fixed)

Opened 5 years ago

Last modified 5 years ago

revise visibility of role methods inherited from regular super class

Reported by: stephan Owned by: stephan
Priority: major Milestone: OTDT_1.2.3
Component: language Version: 1.2.0pre
Keywords: Cc:

Description

When a role class inherits from a regular class, translation to legal Java byte code forces us to do some tricks behind the scenes. In certain situations these tricks may cause java.lang.IllegalAccessError to be thrown at runtime. Also, for the case of inheriting a protected final method the IBM JVM reports:

"JVMVRFY007 final method overridden .."

Thus we might be forced to treat non-public methods inherited from a regular super-class as private within the role. Should then revise OTJLD §1.3.2 accordingly.

Change History

Changed 5 years ago by stephan

  • milestone changed from OTDT_1.2.0 to OTDT_1.2.1

Changed 5 years ago by stephan

  • milestone changed from OTDT_1.2.1 to OTDT_1.2.2

Changed 5 years ago by stephan

  • milestone changed from OTDT_1.2.2 to OTDT_1.2.3

Changed 5 years ago by stephan

  • status changed from new to closed
  • resolution set to fixed

New rule is in OTJLD §1.3.2(e)

Tests are 1.4.7-otjld-access-to-superclass-feature-3f, 1.4.7-otjld-access-to-superclass-feature-4.

Implementation is in r18997.

Consequence: if an inherited non-public method should be exposed via the role, a wrapper method has to be provided by the role.

Note that this rule avoids any special treatment of inherited final methods.

Note: See TracTickets for help on using tickets.