-
Notifications
You must be signed in to change notification settings - Fork 16
EarlyBinder as default #78
Copy link
Copy link
Closed
Labels
T-typesAdd this label so rfcbot knows to poll the types teamAdd this label so rfcbot knows to poll the types teamfinal-comment-periodThe FCP has started, most (if not all) team members are in agreementThe FCP has started, most (if not all) team members are in agreementmajor-changeA major change proposalA major change proposalto-announceAnnounce this issue on triage meetingAnnounce this issue on triage meeting
Metadata
Metadata
Assignees
Labels
T-typesAdd this label so rfcbot knows to poll the types teamAdd this label so rfcbot knows to poll the types teamfinal-comment-periodThe FCP has started, most (if not all) team members are in agreementThe FCP has started, most (if not all) team members are in agreementmajor-changeA major change proposalA major change proposalto-announceAnnounce this issue on triage meetingAnnounce this issue on triage meeting
Type
Fields
Give feedbackNo fields configured for issues without a type.
Proposal
Change all queries which currently have a
bound_Xvariant to returnEarlyBinder<T>by default and remove thebound_Xversion. Add a methodfn EarlyBinder::<T>::subst_identity(self) -> Tif these queries are used in the identity context and don't need to actually substitute anything.Not having
EarlyBinderbe the default can very easily result in incorrect uses of these queries, e.g. https://github.com/rust-lang/rust/blob/736c675d2ab65bcde6554e1b73340c2dbc27c85a/compiler/rustc_hir_analysis/src/astconv/mod.rs#L2720 which I found while reviewing rust-lang/rust#101947. Thenormalize_tynormalizestype_of(def_id)in the wrong environment as we only callsubstafterwards.Mentors or Reviewers
I am available to mentor and review this work.
Process
The main points of the Major Change Process are as follows:
@rustbot second.-C flag, then full team check-off is required.@rfcbot fcp mergeon either the MCP or the PR.You can read more about Major Change Proposals on forge.
Comments
This issue is not meant to be used for technical discussion. There is a Zulip stream for that. Use this issue to leave procedural comments, such as volunteering to review, indicating that you second the proposal (or third, etc), or raising a concern that you would like to be addressed.