Skip to content

Commit d1b810d

Browse files
lqdcompiler-errors
authored andcommitted
remove unneeded let bindings of unit value in parser
1 parent 4ddadff commit d1b810d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

crates/formality-macros/src/parse.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,22 +188,22 @@ fn parse_variant_with_attr(
188188
spec::FormalitySpecSymbol::Keyword { ident } => {
189189
let literal = as_literal(ident);
190190
quote_spanned!(ident.span() =>
191-
let () = __p.expect_keyword(#literal)?;
191+
__p.expect_keyword(#literal)?;
192192
)
193193
}
194194

195195
spec::FormalitySpecSymbol::Char { punct } => {
196196
let literal = Literal::character(punct.as_char());
197197
quote_spanned!(
198198
punct.span() =>
199-
let () = __p.expect_char(#literal)?;
199+
__p.expect_char(#literal)?;
200200
)
201201
}
202202

203203
spec::FormalitySpecSymbol::Delimeter { text } => {
204204
let literal = Literal::character(*text);
205205
quote!(
206-
let () = __p.expect_char(#literal)?;
206+
__p.expect_char(#literal)?;
207207
)
208208
}
209209
});

0 commit comments

Comments
 (0)