[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

resolveConcreteDispatch() and resolveAbstractDispatch()



Hello,

I am reading through the Hierarchy.java, and I have a few observations:

1. resolveConcreteDispatch ignore method attributes

resolveConcreteDispatch() attempts to locate the actual method invoked for a
given class c, and method m. If the method is not implemented by class c
itself, it checks c's superclass and so on. If it doesn't find one after
going through the entire class chain, it throws a run-time exception.

My question is: if the superclass c implements a method of signature with a
private attribute, doesn't this algorithm returns a false positive? It
should throw a run-time exception but doesn't appear to do so.

2. resolveAbstractDispatch()
Similar to 1.

I have yet to fully investigate of the full impact of package-protected
methods. What I am seeing in my experiments so far are strange.

Kind regards,
Stephen