Skip to content
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

Remove From impls for unstable types that break inference #123830

Merged
merged 1 commit into from Apr 12, 2024

Conversation

tgross35
Copy link
Contributor

@tgross35 tgross35 commented Apr 11, 2024

Adding additional From implementations that fit f32::from(<unaffixed float>) broke inference. Remove these for now.

I added a test to make sure this doesn't quietly change in the future, even though the behavior is not technically guaranteed #123824 (comment)

Fixes: #123824

@rustbot
Copy link
Collaborator

rustbot commented Apr 11, 2024

r? @Nilstrieb

rustbot has assigned @Nilstrieb.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Apr 11, 2024
Adding additional `From` implementations that fit `f32::from(<unaffixed
float>)` broke inference. Remove these for now.

Fixes: <rust-lang#123824>
@tgross35 tgross35 force-pushed the f16-f128-from-inference-fix branch from f48cd1c to 9bcc988 Compare April 11, 2024 22:04
@tgross35
Copy link
Contributor Author

This only changes unstable API so I think it ok for somebody from libs (rather than libs-api) to review.

@rustbot label +F-f16_and_f128

@rustbot rustbot added the F-f16_and_f128 `#![feature(f16_and_f128)]` label Apr 11, 2024
@Nilstrieb
Copy link
Member

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Apr 12, 2024

📌 Commit 9bcc988 has been approved by Nilstrieb

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Apr 12, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Apr 12, 2024
…iaskrgr

Rollup of 3 pull requests

Successful merges:

 - rust-lang#123796 (Remove unused cargo-platform dependency from tidy)
 - rust-lang#123830 (Remove `From` impls for unstable types that break inference)
 - rust-lang#123842 (fix typo in pin.rs)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit bcf24d6 into rust-lang:master Apr 12, 2024
11 checks passed
@rustbot rustbot added this to the 1.79.0 milestone Apr 12, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Apr 12, 2024
Rollup merge of rust-lang#123830 - tgross35:f16-f128-from-inference-fix, r=Nilstrieb

Remove `From` impls for unstable types that break inference

Adding additional `From` implementations that fit `f32::from(<unaffixed float>)` broke inference. Remove these for now.

I added a test to make sure this doesn't quietly change in the future, even though the behavior is not technically guaranteed rust-lang#123824 (comment)

Fixes: <rust-lang#123824>
@tgross35 tgross35 deleted the f16-f128-from-inference-fix branch April 12, 2024 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-f16_and_f128 `#![feature(f16_and_f128)]` S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Type inference failure for f32
4 participants