Skip to content

Commit

Permalink
&option<_> -> option<&_>
Browse files Browse the repository at this point in the history
  • Loading branch information
davidszotten committed Jul 31, 2023
1 parent 61a895d commit f7ead78
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions crates/ruff_python_codegen/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1193,7 +1193,12 @@ impl<'a> Generator<'a> {
conversion,
format_spec,
range: _range,
}) => self.unparse_formatted(value, debug_text, *conversion, format_spec.as_deref()),
}) => self.unparse_formatted(
value,
debug_text.as_ref(),
*conversion,
format_spec.as_deref(),
),
Expr::JoinedStr(ast::ExprJoinedStr {
values,
range: _range,
Expand Down Expand Up @@ -1386,7 +1391,7 @@ impl<'a> Generator<'a> {
fn unparse_formatted(
&mut self,
val: &Expr,
debug_text: &Option<DebugText>,
debug_text: Option<&DebugText>,
conversion: ConversionFlag,
spec: Option<&Expr>,
) {
Expand Down Expand Up @@ -1445,7 +1450,12 @@ impl<'a> Generator<'a> {
conversion,
format_spec,
range: _range,
}) => self.unparse_formatted(value, debug_text, *conversion, format_spec.as_deref()),
}) => self.unparse_formatted(
value,
debug_text.as_ref(),
*conversion,
format_spec.as_deref(),
),
_ => unreachable!(),
}
}
Expand Down

0 comments on commit f7ead78

Please sign in to comment.