From be40bbd2fb7e077b27d346a0b9249d309b9ca690 Mon Sep 17 00:00:00 2001 From: Mazdak Farrokhzad Date: Sat, 12 Oct 2019 06:12:00 +0200 Subject: [PATCH] make tidy happy --- src/libsyntax/parse/parser/diagnostics.rs | 12 ++++++++++-- src/libsyntax/parse/parser/stmt.rs | 4 +++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/src/libsyntax/parse/parser/diagnostics.rs b/src/libsyntax/parse/parser/diagnostics.rs index 6a4a6c0f16f95..06982c789db8b 100644 --- a/src/libsyntax/parse/parser/diagnostics.rs +++ b/src/libsyntax/parse/parser/diagnostics.rs @@ -180,7 +180,11 @@ impl<'a> Parser<'a> { self.sess.span_diagnostic.struct_span_fatal(sp, m) } - pub(super) fn span_fatal_err>(&self, sp: S, err: Error) -> DiagnosticBuilder<'a> { + pub(super) fn span_fatal_err>( + &self, + sp: S, + err: Error, + ) -> DiagnosticBuilder<'a> { err.span_err(sp, self.diagnostic()) } @@ -1174,7 +1178,11 @@ impl<'a> Parser<'a> { /// /// If `break_on_block` is `Break`, then we will stop consuming tokens /// after finding (and consuming) a brace-delimited block. - pub(super) fn recover_stmt_(&mut self, break_on_semi: SemiColonMode, break_on_block: BlockMode) { + pub(super) fn recover_stmt_( + &mut self, + break_on_semi: SemiColonMode, + break_on_block: BlockMode, + ) { let mut brace_depth = 0; let mut bracket_depth = 0; let mut in_block = false; diff --git a/src/libsyntax/parse/parser/stmt.rs b/src/libsyntax/parse/parser/stmt.rs index 4b1fdb2eef3a5..d54d9c4b8e9fa 100644 --- a/src/libsyntax/parse/parser/stmt.rs +++ b/src/libsyntax/parse/parser/stmt.rs @@ -372,7 +372,9 @@ impl<'a> Parser<'a> { } /// Parses a block. Inner attributes are allowed. - pub(super) fn parse_inner_attrs_and_block(&mut self) -> PResult<'a, (Vec, P)> { + pub(super) fn parse_inner_attrs_and_block( + &mut self + ) -> PResult<'a, (Vec, P)> { maybe_whole!(self, NtBlock, |x| (Vec::new(), x)); let lo = self.token.span;