On Mon, 13 Mar 2023 18:13:23 GMT, Pavel Rappo <[email protected]> wrote:

>> Please review this explorative refactoring for VisibleMemberTable (VMT).
>> 
>> This is the first round of refactoring for VMT. This round is about *method 
>> members*: declared (overriding and not) and inherited.
>> 
>> During this work I gained some insight into internal workings of VMT, fixed 
>> what was feasible and left TODOs and FIXMEs for everything else. Leaving 
>> those comments might look untidy, but leaving them out is wasteful: they 
>> clearly mark issues that should be revisited in upcoming rounds of 
>> refactoring.
>> 
>> As I see it today, the main issue with VMT is that implements complex and 
>> error-prone computations from Java Language Specification (JLS) by hand. For 
>> example, VMT interprets JLS rules for relations such as _inherits_, 
>> _overrides_ and _hides_. As one would imagine, sometimes VMT does it 
>> incorrectly. It would be better to eventually re-implement VMT using 
>> `javax.lang.model` as much as possible. Unlike that of `jdk.javadoc`, the 
>> day job of `javax.lang.model` is to provide JLS services.
>
> Pavel Rappo has updated the pull request with a new target base due to a 
> merge or a rebase. The incremental webrev excludes the unrelated changes 
> brought in by the merge/rebase. The pull request contains 54 additional 
> commits since the last revision:
> 
>  - Respond to feedback
>    
>    Moves comment to the record declaration.
>  - Respond to feedback
>    
>    Stores superclasses and parents in sets, not lists.
>  - Merge branch 'master' into 8300517
>  - Clarify some assertions
>  - Respond to feedback
>  - Remove trailing whitespace (to please jcheck)
>  - Comment method accessibility for inheritance
>  - Rename VisibleMemberTable.isInherited for clarity
>    
>    It's about _access control_ and has nothing to do with inheritance.
>  - Add FIXMEs to VisibleMemberTable.computeVisibleMethods
>  - Comment VisibleMemberTable.computeVisibleMethods
>  - ... and 44 more: https://git.openjdk.org/jdk/compare/afb67300...42035af7

Marked as reviewed by jjg (Reviewer).

-------------

PR: https://git.openjdk.org/jdk/pull/12887

Reply via email to