-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EarlyBinder
as default
#78
Labels
final-comment-period
The FCP has started, most (if not all) team members are in agreement
major-change
A major change proposal
T-types
Add this label so rfcbot knows to poll the types team
to-announce
Announce this issue on triage meeting
Comments
lcnr
added
major-change
A major change proposal
T-types
Add this label so rfcbot knows to poll the types team
labels
Nov 21, 2022
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. cc @rust-lang/types |
@rustbot second |
rustbot
added
the
final-comment-period
The FCP has started, most (if not all) team members are in agreement
label
Nov 21, 2022
closing as accepted |
bors
added a commit
to rust-lang-ci/rust
that referenced
this issue
Jan 14, 2023
Switch to `EarlyBinder` for `const_param_default` and `impl_trait_ref` queries Part of the work to close rust-lang#105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This PR adds `EarlyBinder` to the return type of `const_param_default` and `impl_trait_ref`, and removes their `bound_X` variants. r? `@lcnr`
matthiaskrgr
added a commit
to matthiaskrgr/rust
that referenced
this issue
Jan 17, 2023
…s, r=lcnr Switch to `EarlyBinder` for `item_bounds` query Part of the work to finish rust-lang#105779 (also see rust-lang/types-team#78). Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `item_bounds` query and removes `bound_item_bounds`. r? `@lcnr`
bors
added a commit
to rust-lang-ci/rust
that referenced
this issue
Jan 27, 2023
Switch to `EarlyBinder` for `fn_sig` query Part of the work to finish rust-lang#105779 (also see rust-lang/types-team#78). Several queries `X` have a `bound_X` variant that wraps the output in [`EarlyBinder`](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/ty/subst/struct.EarlyBinder.html). This adds `EarlyBinder` to the return type of the `fn_sig` query and removes `bound_fn_sig`. r? `@lcnr`
bors
added a commit
to rust-lang/miri
that referenced
this issue
Jan 31, 2023
Switch to `EarlyBinder` for `fn_sig` query Part of the work to finish #105779 (also see rust-lang/types-team#78). Several queries `X` have a `bound_X` variant that wraps the output in [`EarlyBinder`](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/ty/subst/struct.EarlyBinder.html). This adds `EarlyBinder` to the return type of the `fn_sig` query and removes `bound_fn_sig`. r? `@lcnr`
bjorn3
pushed a commit
to rust-lang/rustc_codegen_cranelift
that referenced
this issue
Feb 6, 2023
Switch to `EarlyBinder` for `fn_sig` query Part of the work to finish #105779 (also see rust-lang/types-team#78). Several queries `X` have a `bound_X` variant that wraps the output in [`EarlyBinder`](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/ty/subst/struct.EarlyBinder.html). This adds `EarlyBinder` to the return type of the `fn_sig` query and removes `bound_fn_sig`. r? `@lcnr`
ckxkexing
added a commit
to ckxkexing/rust
that referenced
this issue
Feb 17, 2023
Switch to `EarlyBinder` for `type_of` query Part of the work to finish rust-lang#105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `type_of` query and removes `bound_type_of`. r? `@lcnr`
bors
added a commit
to rust-lang-ci/rust
that referenced
this issue
Feb 17, 2023
Switch to `EarlyBinder` for `type_of` query Part of the work to finish rust-lang#105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `type_of` query and removes `bound_type_of`. r? `@lcnr`
RalfJung
pushed a commit
to RalfJung/miri
that referenced
this issue
Feb 18, 2023
Switch to `EarlyBinder` for `type_of` query Part of the work to finish #105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `type_of` query and removes `bound_type_of`. r? `@lcnr`
Jarcho
pushed a commit
to Jarcho/rust-clippy
that referenced
this issue
Feb 25, 2023
Switch to `EarlyBinder` for `type_of` query Part of the work to finish #105779 and implement rust-lang/types-team#78. Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This adds `EarlyBinder` to the return type of the `type_of` query and removes `bound_type_of`. r? `@lcnr`
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
final-comment-period
The FCP has started, most (if not all) team members are in agreement
major-change
A major change proposal
T-types
Add this label so rfcbot knows to poll the types team
to-announce
Announce this issue on triage meeting
Proposal
Change all queries which currently have a
bound_X
variant to returnEarlyBinder<T>
by default and remove thebound_X
version. Add a methodfn EarlyBinder::<T>::subst_identity(self) -> T
if these queries are used in the identity context and don't need to actually substitute anything.Not having
EarlyBinder
be 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_ty
normalizestype_of(def_id)
in the wrong environment as we only callsubst
afterwards.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 merge
on 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.
The text was updated successfully, but these errors were encountered: