Uh oh!
There was an error while loading. Please reload this page.
Clarify generic type parameter ordering - #2289
Conversation
JelleZijlstra
commented
May 21, 2026
@BHUVANSH855 please do not keep merging main into your branch unless there is an actual merge conflict. |
JelleZijlstra
left a comment
There was a problem hiding this comment.
I think we should add a section header "Type parameter ordering", starting at line 487 or so. Currently this is in a section "Arbitrary generic types as base classes", which isn't really apposite.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
JelleZijlstra
commented
May 21, 2026
Also, is this already covered sufficiently in the conformance suite? What are the relevant tests that we have? |
BHUVANSH855
commented
May 21, 2026
Addressed the requested changes:
There is already conformance coverage for This PR expands the spec wording to make the broader ordering rules explicit, including |
Summary
Clarify how type parameter ordering is determined for generic classes.
This expands the existing wording in the generics spec to explicitly
cover:
Generic[...]base classesProtocol[...]base classesThe updated wording also clarifies that a bare
Protocolbase classdoes not affect type parameter ordering.
Closes#2059