We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 50e38b5 + d8df631 commit f4c5c34Copy full SHA for f4c5c34
compiler/rustc_parse/src/parser/expr.rs
@@ -2910,7 +2910,8 @@ impl<'a> Parser<'a> {
2910
}
2911
2912
2913
- fn parse_for_head(&mut self) -> PResult<'a, (Box<Pat>, Box<Expr>)> {
+ // Public to use it for custom `for` expressions in rustfmt forks like https://github.com/tucant/rustfmt
2914
+ pub fn parse_for_head(&mut self) -> PResult<'a, (Box<Pat>, Box<Expr>)> {
2915
let begin_paren = if self.token == token::OpenParen {
2916
// Record whether we are about to parse `for (`.
2917
// This is used below for recovery in case of `for ( $stuff ) $block`
0 commit comments