Fix trait method resolution on an adjusted never type#156047
Fix trait method resolution on an adjusted never type#156047JonathanBrouwer wants to merge 2 commits intorust-lang:mainfrom
Conversation
|
|
There was a problem hiding this comment.
Note that this PR allows more code to compile on stable, for example see this test.
There was a problem hiding this comment.
If this is a problem we could delay the problem by putting this change behind the never_type feature gate
There was a problem hiding this comment.
I think this a reasonable change, I would expect us to emit a FCW here, I don't want to support this permanently or more importantly, this may overlap with other kinds of inference fallback in the future, so we generally don't want users to rely on this
This comment has been minimized.
This comment has been minimized.
75d6b9a to
d72e38a
Compare
|
Reminder, once the PR becomes ready for a review, use |
This comment has been minimized.
This comment has been minimized.
d72e38a to
3787326
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
| } | ||
|
|
||
| declare_lint! { | ||
| /// The `trait_method_on_coerced_never_type` lint detects situations in which a never type, which |
There was a problem hiding this comment.
I'm really unsure of what the correct terminology is, both for the lint definition and the diagnostic, so please give feedback on this
| "detects trait method calls on an coerced never type", | ||
| @future_incompatible = FutureIncompatibleInfo { | ||
| reason: fcw!(FutureReleaseError #156047), | ||
| report_in_deps: true, |
There was a problem hiding this comment.
I decided on a lint with level Warn with report_in_deps: true. If something else is desired, let me know
3787326 to
a8f68d6
Compare
This comment has been minimized.
This comment has been minimized.
a8f68d6 to
2dd2577
Compare
This comment has been minimized.
This comment has been minimized.
2dd2577 to
388ae0f
Compare
Fixes #143349
r? @WaffleLapkin
cc @lcnr