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

Implement formatting for let_chains #5495

Closed
wants to merge 2 commits into from

Conversation

goffrie
Copy link
Contributor

@goffrie goffrie commented Aug 10, 2022

Currently, if-statements with let chains in them are completely skipped, because format_expr fails on the ExprKind::Let.

Implement it by copying some logic from ControlFlow::rewrite_pat_expr. Then, simplify ControlFlow by removing explicit support for if let/while let, instead delegating to format_expr. Some logic still remains to support for <pat> in <expr>, however.

@calebcartwright
Copy link
Member

Thank you for the contribution but I am going to close as this is a duplicate of another PR that is currently blocked. More info in the summary in #5203 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants