librustc: Apply coercions to return expressions.#14735
Closed
luqmana wants to merge 2 commits intorust-lang:masterfrom
Closed
librustc: Apply coercions to return expressions.#14735luqmana wants to merge 2 commits intorust-lang:masterfrom
luqmana wants to merge 2 commits intorust-lang:masterfrom
Conversation
Member
|
\o/ I was just about to do this for DST too |
Member
There was a problem hiding this comment.
Where there is an expected type, you probably want to write that instead of the actual type for the block.
I think you also need to use a coercion rather than a subtype check when checking ExprRet and the tail expr in check_fn
Contributor
Author
|
This needs a bit more work so I'll just close it for now. |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Jun 5, 2023
internal: Forbid canonicalization of paths and normalize all rust-project.json paths Closes rust-lang/rust-analyzer#14728 cc rust-lang/rust-analyzer#14430 - Removes canonicalization (and forbids it from being used in a sense, clippy could help here again with its lint in the future) - Normalizes all paths in rust-project.json which we weren't doing in some cases
flip1995
pushed a commit
to flip1995/rust
that referenced
this pull request
May 31, 2025
…ust-lang#14735) Closes rust-lang/rust-clippy#14734 changelog: [`needless_for_each`] wrong suggestions when closure has no braces
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #12755.
r? @nikomatsakis