We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Replace ExprType::Statement with ExprType::SubExpression if the statement is the last statement within its enclosing block.
ExprType::Statement
ExprType::SubExpression
rustfmt/src/expr.rs
Line 585 in 1cea171
One way to implement this is to add a wrapper type over ast::Stmt which holds the information about whether it's the last statement or not:
ast::Stmt
struct Statement<'ast> { stmt: &'ast ast::Stmt, is_last: bool, }
cc #3614.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Replace
ExprType::Statement
withExprType::SubExpression
if the statement is the last statement within its enclosing block.rustfmt/src/expr.rs
Line 585 in 1cea171
One way to implement this is to add a wrapper type over
ast::Stmt
which holds the information about whether it's the last statement or not:cc #3614.
The text was updated successfully, but these errors were encountered: